Thank you all for the reply.
I tried the below code. The file is a tab delimited file. If there is a null value in first column in the third row then it is pulling the second column from that row and saving it in the output file.
I have a file containing the lines similar to the following entries:
File1.txt:
.....
-rw-r--r-- 1 root staff 4110 Aug 7 17:02 XXX_OrderNum1_date1_time1.txt
-rw-r--r-- 1 root staff 4110 Aug 7 17:02 XXX_OrderNum2_date2_time1.txt
-rw-r--r-- 1 root staff ... (3 Replies)
Dear All,
I have a file name pointer.unl. It's contains the information below:
O|A|4560333089|PBS|AU1|01/04/2003|30/04/2006|D|IGCD|
O|A|4562222089|PBN|AU1|01/02/2006|31/01/2008|D|04065432|
O|A|3454d00089|PKR|AU1|01/03/2008||R|sdcdc|
I only need to extract first... (11 Replies)
Hi everybody
I have some problems with PERL programming.
I have a file with two columns, both with numeric values.
I have to extract the values > 50 from the 2nd columns and sum them among them.
The I have to sum the respective values in the first column on the same line and, at the end, I... (6 Replies)
Can Anyone tell me how to extract the second column of a xls sheet
And compare the content of each row of the column with a .h file.
xls sheet is having only one spreadsheet. (2 Replies)
Hi everyone,
i am new to perl programming, i have a problem in extracting single column from csv file. the column is the 20th column,
please help me..
at present i use this code
#!C:/perl/bin
use warnings;
use strict;
my $file1 = $ARGV;
open FILE1, "<$file1"
or die "Can't... (13 Replies)
Hi All,
Using below command to extract text from a file
grep -E "^.{20}5004" filename.rtf >> 5004This will give all lines with text 5004 starting at position 20.
The file filename.rtf contains several rows (millions). The four characters starting from 20 position is repeating in several... (4 Replies)
Hello Gurus
I have a source file which has the first line as header and the rest are the records
I need to extract the first column from the second line to extract a value
I/P
... (7 Replies)
Hi, it's my first time in this site.
I've a file that look likes
Edges 21 82
Edges 3 22
Edges 34 12
Edges 1 24
Edges 6 2
Edges 12 22
etc. I need extract just the second and third column with the space between them. Thanks:)
Please use code tags next time for your code and data. (4 Replies)
Hi,
I am trying with the below Perl one-liner using regular expression to extract the first and second column of a text file:
perl -p -e "s/\s*(\w+).*/$1/"
perl -p -e "s/\s*.+\s(.+)\s*/$1\n/"
whereas the text file's data looks like:
Error: terminated 2233
Warning: reboot 3434
Warning:... (3 Replies)
Discussion started by: royalibrahim
3 Replies
LEARN ABOUT PHP
db2_field_scale
DB2_FIELD_SCALE(3) 1 DB2_FIELD_SCALE(3)db2_field_scale - Returns the scale of the indicated column in a result setSYNOPSIS
int db2_field_scale (resource $stmt, mixed $column)
DESCRIPTION
Returns the scale of the indicated 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 scale of the specified column. If the specified column does not exist in the result set,
db2_field_scale(3) returns FALSE.
SEE ALSO db2_field_display_size(3), db2_field_name(3), db2_field_num(3), db2_field_precision(3), db2_field_type(3), db2_field_width(3).
PHP Documentation Group DB2_FIELD_SCALE(3)