I have following entries in a file.
I want to toggle the entry of 2nd column. TRUE/FALSE
i tried using
but the problem is, if instead of "tab" space after 1st column, there is a character or multi character space then this won't work.
Entries in the below file is like:
Pls help, if i can use any other editor "sed", "awk" etc.(but i am not too familiar with these)
Hi all,
I need to insert new text and change existing text in a file. For that I used the below line in the command line and got the expected output.
sed '$a\
hi...
' shell > shell1
But I face problem when using the same in script. It is throwing the error as,
sed: command garbled:... (4 Replies)
I have several files that are being generated every 20 minutes. Each file contains 2 columns. The 1st column is Text, 2nd column is Data.
I would like to generate one single file from all these files as follows:
One instance of 1st column Text, followed by 2nd column Data separated by... (5 Replies)
Hi friends,
My file is like:
Second file is :
I need to print the rows present in file one, but in order present in second file....I used
while read gh;do
awk ' $1=="' $gh'" {print >> FILENAME"output"} ' cat listoffirstfile
done < secondfile
but the output I am... (14 Replies)
Hi All,
Please help i have written an ksh script, where i am actually take count of lines in one file and want to update this count to 2nd field of a new file and apend the this into an existing file.
Note the below script is in for loop
-------- I am apending few records in a file... (7 Replies)
Hi Gurus,
I have file content sample:
,5113955056,,TAgent-Suspend
,5119418233,,TAgent-Suspend
,5102119078,,TAgent-Suspend
filenames 120229H5_suspend, 120229H6_unsuspend
I receive those files one of directory /home/temp/
I need following:
1. Backup first /home/temp/ file to... (5 Replies)
I have following entries file abc.txt
abc83.out.remote TRUE
abc84.out.remote TRUE
abc85.out.remote TRUE
abc86.out.remote TRUE
Please help me, how do i toggle the entries listed in 2nd column based on the search patterns (abcxx)
abcxx, i can get... (14 Replies)
I have a csv file formatted like this:
2014-08-21 18:06:26,A,B,12345,123,C,1232,26/08/14 18:07and I'm trying to change it to MM/DD/YYYY HH:MM for both occurances.
I have got this:
awk -F, 'NR <=1 {print;next}{"date +%d/%m/%Y\" \"%H:%m -d\""$1 "\""| getline dte;$1=dte}1' OFS="," test.csvThis... (6 Replies)
hi
I have 2 file with more than 10 columns for both
1st file
apple,0,0,0......
orange,1,2,3.....
mango,2,4,5.....
2nd file
apple,2,3,4,5,6,7...
orange,2,3,4,5,6,8...
watermerlon,2,3,4,5,6,abc...
mango,5,6,7,4,6,def.... (1 Reply)
Discussion started by: tententen
1 Replies
LEARN ABOUT PHP
db2_field_num
DB2_FIELD_NUM(3) 1 DB2_FIELD_NUM(3)db2_field_num - Returns the position of the named column in a result setSYNOPSIS
int db2_field_num (resource $stmt, mixed $column)
DESCRIPTION
Returns the position of the named column in a result set.
PARAMETERS
o $stmt
- Specifies a statement resource containing a result set.
o $column
- Specifies the column in the result set. This can either be an integer representing the 0-indexed position of the column, or a
string containing the name of the column.
RETURN VALUES
Returns an integer containing the 0-indexed position of the named column in the result set. If the specified column does not exist in the
result set, db2_field_num(3) returns FALSE.
SEE ALSO db2_field_display_size(3), db2_field_name(3), db2_field_precision(3), db2_field_scale(3), db2_field_type(3), db2_field_width(3).
PHP Documentation Group DB2_FIELD_NUM(3)