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)
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)
I have the following script, and I want to assign the output ($10 and $5) from awk to N and L:
grdinfo data.grd | awk '{print $10,$5}'| read N L
output from gridinfo data.grd is: data.grd 50 100 41 82 -2796 6944 0.016 0.016 3001 2461. where N and L is suppose to be 3001 and 100. I use... (8 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
hwloc-distances
HWLOC-DISTANCES(1) hwloc HWLOC-DISTANCES(1)NAME
hwloc-distances - Displays distance matrices
SYNOPSIS
hwloc-distances [options]
OPTIONS -l --logical
Display hwloc logical indexes (default) instead of physical/OS indexes.
-p --physical
Display OS/physical indexes instead of hwloc logical indexes.
-i <file>, --input <file>
Read topology from XML file <file> (instead of discovering the topology on the local machine). If <file> is "-", the standard input
is used. XML support must have been compiled in to hwloc for this option to be usable.
-i <directory>, --input <directory>
Read topology from the chroot specified by <directory> (instead of discovering the topology on the local machine). This option is
generally only available on Linux. The chroot was usually created by gathering another machine topology with hwloc-gather-topology.
-i <specification>, --input <specification>
Simulate a fake hierarchy (instead of discovering the topology on the local machine). If <specification> is "node:2 pu:3", the
topology will contain two NUMA nodes with 3 processing units in each of them. The <specification> string must end with a number of
PUs.
--if <format>, --input-format <format>
Enforce the input in the given format, among xml, fsroot and synthetic.
--restrict <cpuset>
Restrict the topology to the given cpuset.
-v Verbose messages.
--version
Report version and exit.
DESCRIPTION
hwloc-distances displays also distance matrices attached to the topology. A breadth-first traversal of the topology is performed starting
from the root to find all distance matrices.
NOTE: lstopo may also display distance matrices in its verbose textual output. However lstopo only prints matrices that cover the entire
topology while hwloc-distances also displays matrices that ignore part of the topology.
EXAMPLES
On a quad-socket opteron machine:
$ hwloc-distances
Latency matrix between 4 NUMANodes (depth 2) by logical indexes:
index 0 1 2 3
0 1.000 1.600 2.200 2.200
1 1.600 1.000 2.200 2.200
2 2.200 2.200 1.000 1.600
3 2.200 2.200 1.600 1.000
RETURN VALUE
Upon successful execution, hwloc-distances returns 0.
hwloc-distances will return nonzero if any kind of error occurs, such as (but not limited to) failure to parse the command line.
SEE ALSO hwloc(7), lstopo(1)1.4.1 Feb 27, 2012 HWLOC-DISTANCES(1)