Hi Guys !
I am new to unix and want to find out how we can make sql statement data to shell script variable?
Any help/suggestion is greatly appreciated
-Chandra (1 Reply)
Dear Friends
I have text file as like below,
AAAAA|BHBHBH|VERYSMART
AAAAA| KKKKKK|GOOD
BBBBBB|JJJJJJJ|VERYGOOD
CCCCC|HJHJHJ|BETTER
CCCCC|UUUUU|GOOD
i need to split into seperate files based on column 1 like as below
AAAAA.TXT contains
--------------------
BHBHBH.VERYSMART... (4 Replies)
:confused: Hi UNIX gurus,
I am facing a typical problem while assigining while assigining output of awk to a variable.
I have a fixed length file say myinputfile.txt
When I allow the value/output of an awk to be redirected to a file, it works fine. i.e.
awk "/^.{232}$acctNum/ {... (8 Replies)
Hi Friends...
Please assist me to assign the result of a SQL query that results two column, to two variables.
Pls find the below code that I write for assigning one column to one variable. and please correct if anything wrong..
#! /bin/sh
no='
sqlplus -s uname/password@DBname... (4 Replies)
Dear All,
we have a command output which looks like :
Total 200 queues in 30000 Kbytes
and we're going to get "200" and "30000" for further process. currently, i'm using :
numA=echo $OUTPUT | awk '{print $2}'
numB=echo $OUTPUT | awk '{print $5}'
my question is : can I use just one... (4 Replies)
How can I assign a variable to an variable. IE $car=honda
One way I can do it is export $car=honda
or
let $car=2323
Is there any other ways to preform this task (3 Replies)
I have a log file that has certain fields that I want to evaluate, and depending on the value in those fields, I want to put the value of a different field in that line in a particular variable that I'll use later on down the log file. Sort of like setting a switch to change what I do with a bunch... (5 Replies)
I launch 'netstat -a', if string 'ESTABLISHED' found, then VAR=1
#!/bin/bash
VAR=0;
netstat -a | awk '$6 ~ /ESTABLISHED/ {VAR=1}'
I cannot find the right syntax.
thanx guys! (3 Replies)
Hi Gurus,
I have a script which assign awk output to shell variable. current it uses two awk command to assign value to two variables. I want to use one command to assign two values to two variables. I tried the code, but it does't work. kindly provide your suggestion.
current code... (2 Replies)
Discussion started by: green_k
2 Replies
LEARN ABOUT DEBIAN
grdinfo
GRDINFO(l) GRDINFO(l)
NAME
grdinfo - Get information about the contents of a 2-D grd file
SYNOPSIS
grdinfo grdfiles [ -C ] [ -D ] [ -F ] [ -L1 ] [ -L2 ] [ -M ] [ -V ]
DESCRIPTION
grdinfo reads a 2-D binary grd file and reports various statistics for the (x,y,z) data in the grdfile. The output information contains the
minimum/maximum values for x, y, and z, where the min/max of z occur, the x- and y-increments, and the number of x and y nodes, and
[optionally] the mean, standard deviation, and/or the median, L1 scale of z, and number of nodes set to NaN.
grdfile
The name of one or several 2-D grd files.
OPTIONS
No space between the option flag and the associated arguments.
-C Formats the report using tab-separated fields on a single line. The output is w e s n z0 z1 dx dy nx ny [ x0 y0 x1 y1 ] [ med scale
] [ mean std rms] [n_nan]. The data in brackets are output only if the corresponding options -M, -L1, -L2, and -M are used, respec-
tively.
-D Report grid domain and x/y-increments using dd:mm:ss[.fff] notation [Default is decimal]. Does not apply to the -C option.
-F Report grid domain and x/y-increments world mapping format [Default is generic]. Does not apply to the -C option.
-L1 Report median and L1 scale of z (L1 scale = 1.4826 * Median Absolute Deviation (MAD)).
-L2 Report mean and standard deviation of z.
-M Find and report the location of min/max z-values, and count and report the number of nodes set to NaN, if any.
-V Selects verbose mode, which will send progress reports to stderr [Default runs "silently"].
EXAMPLES
To obtain all the information about the data set in file hawaii_topo.grd, try
grdinfo -L1 -L2 -M hawaii_topo.grd
SEE ALSO gmt(1gmt), grd2cpt(1gmt), grd2xyz(1gmt), grdedit(1gmt)
1 Jan 2004 GRDINFO(l)