Sponsored Content
Top Forums Programming how to insert and delete characters in the middle of file Post 56514 by ivancheung on Monday 4th of October 2004 11:30:16 PM
Old 10-05-2004
Isn't there any other clever and efficient way to do that?
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

awk insert character in the middle of a line

I'm trying to insert a single character at position 11 in everyline of a file. My input file looks like this: 456781 ~Y~12345 456782 ~N~12300 and I want my output to look like this: 45678~1 ~Y~12345 45678~2 ~N~12300 I tried the following awk code, but it's not working:... (3 Replies)
Discussion started by: mmarino
3 Replies

2. Shell Programming and Scripting

insert text into the middle of a original file

how do u insert text into a specific place in a file, say the middle for example, without changing the name for that file (1 Reply)
Discussion started by: mopimp
1 Replies

3. Shell Programming and Scripting

How to insert text into first line of the file and middle of the file?

Script 1 Pre-requisites Create a file with x amount of lines in it, the content of your choice. Write a script that takes two arguments. The first being a line of text, the second being your newly created file. The script should take the first argument and insert it into the very top (the... (3 Replies)
Discussion started by: ali hussain
3 Replies

4. Shell Programming and Scripting

How to insert the 1st arg into the middle of the file

I wrote a script like #!/bin/bash echo $1 > temp cat $2 >> temp mv temp $2 now I have problem appending the above script(only using bash shell) so that it now inserts the first argument into the middle of the file. I have tried using $(('wc -l < file' / 2 )) but invain so could any one... (4 Replies)
Discussion started by: boris
4 Replies

5. Shell Programming and Scripting

insert one file into middle of another file

how to insert one file into another file not by concatenating as usual done. file1 A B C D E F G H I J K L file2 23455 33444 33334 33345 Output shud be 23455 A B C D (4 Replies)
Discussion started by: cdfd123
4 Replies

6. Shell Programming and Scripting

insert text in the middle of a file

I want to insert a text into the middle of a file (3 Replies)
Discussion started by: relle
3 Replies

7. UNIX for Dummies Questions & Answers

How to insert text in the middle of a file

Hey guys, how do we take a line of text as an argument from a user and then insert it in the middle of a file irrespective of the number of lines in the file. I am trying to do this without SED or AWK. Inserting it in the beginning and at the end is easy, but i am trying to accomplish inserting... (6 Replies)
Discussion started by: kartikkumar84@g
6 Replies

8. Shell Programming and Scripting

How do I insert a line in the middle of a file in BASH?

I have tried sed '/6/a text_to_inserted' file > newfile but this inserts test_to_insert at random places in file and i want it in specific location, which is line 6. can anyone help.... (6 Replies)
Discussion started by: phenom
6 Replies

9. Shell Programming and Scripting

How to insert text in the middle of a file?

Hi, So far i've made a script that takes two argument, 1st is the contents and the 2nd is the named file. At the moment i've managed to insert new contents as a new line at the top, but i want to ask how can you insert contents in the middle of the file? Source Code #!/bin/bash #Write... (3 Replies)
Discussion started by: zen10
3 Replies

10. Shell Programming and Scripting

delete blank line from middle of a file

All, I have a file which contains two entry with spaces (either one or more than one space). ex. /tmp/scripts/sql CUST_YR_END_INI.sql /tmp/scripts/sql CUST_WK_END_INI.sql /tmp/scripts/sql CUST_MTH_END_INI.sql /tmp/scripts/sql CUST_YR_END_INC.sql now I want to... (11 Replies)
Discussion started by: anshu ranjan
11 Replies
DateTime::Locale::ms_BN(3)				User Contributed Perl Documentation				DateTime::Locale::ms_BN(3)

NAME
DateTime::Locale::ms_BN SYNOPSIS
use DateTime; my $dt = DateTime->now( locale => 'ms_BN' ); print $dt->month_name(); DESCRIPTION
This is the DateTime locale package for Malay Brunei. DATA
This locale inherits from the DateTime::Locale::ms locale. It contains the following data. Days Wide (format) Isnin Selasa Rabu Khamis Jumaat Sabtu Ahad Abbreviated (format) Isn Sel Rab Kha Jum Sab Ahd Narrow (format) 2 3 4 5 6 7 1 Wide (stand-alone) Isnin Selasa Rabu Khamis Jumaat Sabtu Ahad Abbreviated (stand-alone) Isn Sel Rab Kha Jum Sab Ahd Narrow (stand-alone) 2 3 4 5 6 7 1 Months Wide (format) Januari Februari Mac April Mei Jun Julai Ogos September Oktober November Disember Abbreviated (format) Jan Feb Mac Apr Mei Jun Jul Ogos Sep Okt Nov Dis Narrow (format) 1 2 3 4 5 6 7 8 9 10 11 12 Wide (stand-alone) Januari Februari Mac April Mei Jun Julai Ogos September Oktober November Disember Abbreviated (stand-alone) Jan Feb Mac Apr Mei Jun Jul Ogos Sep Okt Nov Dis Narrow (stand-alone) 1 2 3 4 5 6 7 8 9 10 11 12 Quarters Wide (format) suku pertama suku kedua suku ketiga suku keempat Abbreviated (format) S1 S2 S3 S4 Narrow (format) 1 2 3 4 Wide (stand-alone) suku pertama suku kedua suku ketiga suku keempat Abbreviated (stand-alone) S1 S2 S3 S4 Narrow (stand-alone) 1 2 3 4 Eras Wide BCE CE Abbreviated S.M. T.M. Narrow S.M. T.M. Date Formats Full 2008-02-05T18:30:30 = 05 Februari 2008 1995-12-22T09:05:02 = 22 Disember 1995 -0010-09-15T04:44:23 = 15 September -10 Long 2008-02-05T18:30:30 = 05 Februari 2008 1995-12-22T09:05:02 = 22 Disember 1995 -0010-09-15T04:44:23 = 15 September -10 Medium 2008-02-05T18:30:30 = 05/02/2008 1995-12-22T09:05:02 = 22/12/1995 -0010-09-15T04:44:23 = 15/09/-010 Short 2008-02-05T18:30:30 = 05/02/2008 1995-12-22T09:05:02 = 22/12/1995 -0010-09-15T04:44:23 = 15/09/-010 Default 2008-02-05T18:30:30 = 05/02/2008 1995-12-22T09:05:02 = 22/12/1995 -0010-09-15T04:44:23 = 15/09/-010 Time Formats Full 2008-02-05T18:30:30 = 6:30:30 PM UTC 1995-12-22T09:05:02 = 9:05:02 AM UTC -0010-09-15T04:44:23 = 4:44:23 AM UTC Long 2008-02-05T18:30:30 = 18:30:30 UTC 1995-12-22T09:05:02 = 9:05:02 UTC -0010-09-15T04:44:23 = 4:44:23 UTC Medium 2008-02-05T18:30:30 = 18:30:30 1995-12-22T09:05:02 = 9:05:02 -0010-09-15T04:44:23 = 4:44:23 Short 2008-02-05T18:30:30 = 18:30 1995-12-22T09:05:02 = 9:05 -0010-09-15T04:44:23 = 4:44 Default 2008-02-05T18:30:30 = 18:30:30 1995-12-22T09:05:02 = 9:05:02 -0010-09-15T04:44:23 = 4:44:23 Datetime Formats Full 2008-02-05T18:30:30 = 05 Februari 2008 6:30:30 PM UTC 1995-12-22T09:05:02 = 22 Disember 1995 9:05:02 AM UTC -0010-09-15T04:44:23 = 15 September -10 4:44:23 AM UTC Long 2008-02-05T18:30:30 = 05 Februari 2008 18:30:30 UTC 1995-12-22T09:05:02 = 22 Disember 1995 9:05:02 UTC -0010-09-15T04:44:23 = 15 September -10 4:44:23 UTC Medium 2008-02-05T18:30:30 = 05/02/2008 18:30:30 1995-12-22T09:05:02 = 22/12/1995 9:05:02 -0010-09-15T04:44:23 = 15/09/-010 4:44:23 Short 2008-02-05T18:30:30 = 05/02/2008 18:30 1995-12-22T09:05:02 = 22/12/1995 9:05 -0010-09-15T04:44:23 = 15/09/-010 4:44 Default 2008-02-05T18:30:30 = 05/02/2008 18:30:30 1995-12-22T09:05:02 = 22/12/1995 9:05:02 -0010-09-15T04:44:23 = 15/09/-010 4:44:23 Available Formats d (d) 2008-02-05T18:30:30 = 5 1995-12-22T09:05:02 = 22 -0010-09-15T04:44:23 = 15 EEEd (d EEE) 2008-02-05T18:30:30 = 5 Sel 1995-12-22T09:05:02 = 22 Jum -0010-09-15T04:44:23 = 15 Sab Hm (H:mm) 2008-02-05T18:30:30 = 18:30 1995-12-22T09:05:02 = 9:05 -0010-09-15T04:44:23 = 4:44 hm (h:mm a) 2008-02-05T18:30:30 = 6:30 PM 1995-12-22T09:05:02 = 9:05 AM -0010-09-15T04:44:23 = 4:44 AM Hmm (H:mm) 2008-02-05T18:30:30 = 18:30 1995-12-22T09:05:02 = 9:05 -0010-09-15T04:44:23 = 4:44 Hms (H:mm:ss) 2008-02-05T18:30:30 = 18:30:30 1995-12-22T09:05:02 = 9:05:02 -0010-09-15T04:44:23 = 4:44:23 hms (h:mm:ss a) 2008-02-05T18:30:30 = 6:30:30 PM 1995-12-22T09:05:02 = 9:05:02 AM -0010-09-15T04:44:23 = 4:44:23 AM M (L) 2008-02-05T18:30:30 = 2 1995-12-22T09:05:02 = 12 -0010-09-15T04:44:23 = 9 Md (M-d) 2008-02-05T18:30:30 = 2-5 1995-12-22T09:05:02 = 12-22 -0010-09-15T04:44:23 = 9-15 MEd (E, M-d) 2008-02-05T18:30:30 = Sel, 2-5 1995-12-22T09:05:02 = Jum, 12-22 -0010-09-15T04:44:23 = Sab, 9-15 MMdd (dd/MM) 2008-02-05T18:30:30 = 05/02 1995-12-22T09:05:02 = 22/12 -0010-09-15T04:44:23 = 15/09 MMM (LLL) 2008-02-05T18:30:30 = Feb 1995-12-22T09:05:02 = Dis -0010-09-15T04:44:23 = Sep MMMd (MMM d) 2008-02-05T18:30:30 = Feb 5 1995-12-22T09:05:02 = Dis 22 -0010-09-15T04:44:23 = Sep 15 MMMEd (E MMM d) 2008-02-05T18:30:30 = Sel Feb 5 1995-12-22T09:05:02 = Jum Dis 22 -0010-09-15T04:44:23 = Sab Sep 15 MMMMd (MMMM d) 2008-02-05T18:30:30 = Februari 5 1995-12-22T09:05:02 = Disember 22 -0010-09-15T04:44:23 = September 15 MMMMdd (dd MMMM) 2008-02-05T18:30:30 = 05 Februari 1995-12-22T09:05:02 = 22 Disember -0010-09-15T04:44:23 = 15 September MMMMEd (E MMMM d) 2008-02-05T18:30:30 = Sel Februari 5 1995-12-22T09:05:02 = Jum Disember 22 -0010-09-15T04:44:23 = Sab September 15 ms (mm:ss) 2008-02-05T18:30:30 = 30:30 1995-12-22T09:05:02 = 05:02 -0010-09-15T04:44:23 = 44:23 y (y) 2008-02-05T18:30:30 = 2008 1995-12-22T09:05:02 = 1995 -0010-09-15T04:44:23 = -10 yM (y-M) 2008-02-05T18:30:30 = 2008-2 1995-12-22T09:05:02 = 1995-12 -0010-09-15T04:44:23 = -10-9 yMEd (EEE, y-M-d) 2008-02-05T18:30:30 = Sel, 2008-2-5 1995-12-22T09:05:02 = Jum, 1995-12-22 -0010-09-15T04:44:23 = Sab, -10-9-15 yMMM (y MMM) 2008-02-05T18:30:30 = 2008 Feb 1995-12-22T09:05:02 = 1995 Dis -0010-09-15T04:44:23 = -10 Sep yMMMEd (EEE, y MMM d) 2008-02-05T18:30:30 = Sel, 2008 Feb 5 1995-12-22T09:05:02 = Jum, 1995 Dis 22 -0010-09-15T04:44:23 = Sab, -10 Sep 15 yMMMM (y MMMM) 2008-02-05T18:30:30 = 2008 Februari 1995-12-22T09:05:02 = 1995 Disember -0010-09-15T04:44:23 = -10 September yQ (y Q) 2008-02-05T18:30:30 = 2008 1 1995-12-22T09:05:02 = 1995 4 -0010-09-15T04:44:23 = -10 3 yQQQ (y QQQ) 2008-02-05T18:30:30 = 2008 S1 1995-12-22T09:05:02 = 1995 S4 -0010-09-15T04:44:23 = -10 S3 yyQ (Q yy) 2008-02-05T18:30:30 = 1 08 1995-12-22T09:05:02 = 4 95 -0010-09-15T04:44:23 = 3 -10 yyyyMM (MM/yyyy) 2008-02-05T18:30:30 = 02/2008 1995-12-22T09:05:02 = 12/1995 -0010-09-15T04:44:23 = 09/-010 yyyyMMMM (MMMM y) 2008-02-05T18:30:30 = Februari 2008 1995-12-22T09:05:02 = Disember 1995 -0010-09-15T04:44:23 = September -10 Miscellaneous Prefers 24 hour time? Yes Local first day of the week Isnin SUPPORT
See DateTime::Locale. AUTHOR
Dave Rolsky <autarch@urth.org> COPYRIGHT
Copyright (c) 2008 David Rolsky. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. This module was generated from data provided by the CLDR project, see the LICENSE.cldr in this distribution for details on the CLDR data's license. perl v5.18.2 2017-10-06 DateTime::Locale::ms_BN(3)
All times are GMT -4. The time now is 12:45 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy