Hi Guys,
Can you help with the shell script:
I would like to search a fixed width pattern from a file
say for each line from a fixed position and lenght it has to return all rows from the file.
Example:
To search the third column for "def" it has to return 1 and 4th rows only
... (2 Replies)
I have a problem in searching a specific pattern in c files.
My requirement:
I have to find all the division operator in all cfiles.
The problem is, the multi line comments and single line comments will also have forward slash in it.
Even after avoiding these comments also, if both... (6 Replies)
Hello,
I am just getting starting with awk and wondering if anyone could help with the following problem.
I have a large file of data, 50,000 rows x 6 columns. I would like to search in blocks of 500 rows for a maximum value in a specific column and compile an output file that prints the... (3 Replies)
Hi All,
Please can someone assist in the script I have made that searches a pattern in a file and delete the whole line containing the pattern.
#!bin/sh
# The pattern that user want to add to the files
echo "Enter the pattern of the redirect"
read value
# check if the user has... (1 Reply)
Hi,
I need small help from you people.
In a directory there are around 150 odd files and few them contain the word "TRACK" and few are not.
How can I find out the the list of those files which doesn't contain the word "TRACK"?
Thanks,
Siba (4 Replies)
in my file i have somthing likre
kpk_12
kpk_1
kpk_1.tcl
kpk_3.tcl
kpk
kpk
kpk
i want search only kpk i am using this cmd /kpk ...results it is showing all . any cmd is ther other then this to search exactword in this example kpk it shoulsnot show kpk_* etc
Thanks in Advance
... (2 Replies)
Hi,
Can you please help me out here? I am trying develop a search pattern to extract certain words from the two strings below.
I want to extract ericsson_msc_live from the 2 strings and then the date, which is a part of the filename just before the .jar extension.
... (19 Replies)
Hi there,
Looking forward to your advice for the below:
I have a file which contains 2 paragraphs related to a particular pattern. I have to search for those paragraphs from a log file and then print a particular line from those paragraphs.
Sample:
I have one file with the fixed... (3 Replies)
I am trying to arrange these columns so that they look like this:
Xray2_1255555 Number of Copies: 1
Boxcar_1387305895 Number of Copies: 2
Fox_1387305896 Number of Copies: 2
But I have one column after another like this:
Xray2_1255555
Number of Copies: 1
Xray2_12444444
Number of... (5 Replies)
Discussion started by: newbie2010
5 Replies
LEARN ABOUT PHP
pg_num_rows
PG_NUM_ROWS(3)PG_NUM_ROWS(3)pg_num_rows - Returns the number of rows in a resultSYNOPSIS
int pg_num_rows (resource $result)
DESCRIPTION pg_num_rows(3) will return the number of rows in a PostgreSQL result resource.
Note
This function used to be called pg_numrows(3).
PARAMETERS
o $result
- PostgreSQL query result resource, returned by pg_query(3), pg_query_params(3) or pg_execute(3) (among others).
RETURN VALUES
The number of rows in the result. On error, -1 is returned.
EXAMPLES
Example #1
pg_num_rows(3) example
<?php
$result = pg_query($conn, "SELECT 1");
$rows = pg_num_rows($result);
echo $rows . " row(s) returned.
";
?>
The above example will output:
1 row(s) returned.
SEE ALSO pg_num_fields(3), pg_affected_rows(3).
PHP Documentation Group PG_NUM_ROWS(3)