06-29-2017
I would approach this problem using AWK.
What have you tried?
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi all,
in my csv file it'll look like this, and of course it may have more columns
US to UK;abc-hq-jcl;multimedia
UK to CN;def-ny-jkl;standard
DE to DM;abc-ab-klm;critical
FD to YM;la-yr-tym;standard
HY to MC;la-yr-ytm;multimedia
GT to KJ;def-ny-jrt;critical
I would like to group... (4 Replies)
Discussion started by: tententen
4 Replies
2. Shell Programming and Scripting
Hi All,
I am newbie to Unix I ve got assignment to work in unix
can you please help me in this regard
There is a sample CSV file
"Username", "Password"
"John1", "Scot1"
"John2", "Scot2"
"John3", "Scot3"
"John4", "Scot4"
If i give the column name as Password and row number as 4 the... (3 Replies)
Discussion started by: JohnGG
3 Replies
3. Shell Programming and Scripting
My scenario is that I need to pick value from third column based on fourth column value, if fourth column value is 1 then first value of third column.Third column (2|3|4|6|1) values are cancatenated.
Main imp point, in my .csv file, third column is having price value with comma (1,20,300), it has... (2 Replies)
Discussion started by: Ganesh L
2 Replies
4. Shell Programming and Scripting
Hi all,
I am new to shell script.I need your help to write a shell script.
I need to write a shell script to extract data from a .csv file where columns are ',' separated.
The file has 5 columns having values say column 1,column 2.....column 5 as below along with their valuesm.... (3 Replies)
Discussion started by: Vivekit82
3 Replies
5. Linux
I have a .CSV file with the below format:
"column 1","column 2","column 3","column 4","column 5","column 6","column 7","column 8","column 9","column 10
"12310","42324564756","a simple string with a , comma","string with or, without commas","string 1","USD","12","70%","08/01/2013",""... (2 Replies)
Discussion started by: dhruuv369
2 Replies
6. Shell Programming and Scripting
input.csv:
Field1,Field2,Field3,Field4,Field4
abc ,123 ,xyz ,000 ,pqr
mno ,123 ,dfr ,111 ,bbb
output:
Field2,Field4
123 ,000
123 ,111
how to fetch the values of Field4 where Field2='123'
I don't want to fetch the values based on column position. Instead want to... (10 Replies)
Discussion started by: bharathbangalor
10 Replies
7. Linux
cat sample.csv
ID,Name,no
1,AAA,1
2,BBB,1
3,AAA,1
4,BBB,1
cut -d',' -f2 sample.csv | sort | uniq
this gives only the 2nd column values
Name
AAA
BBB
How to I get all the columns of CSV along with this? (1 Reply)
Discussion started by: sanvel
1 Replies
8. Shell Programming and Scripting
Hello,
I want to get the maximum value of each record separated by empty line based on the 3rd column of each row within each record?
Input:
A1 chr5D 634 7 82 707
A2 chr5D 637 6 82 713
A3 chr5D 637 5 82 713
A4 chr5D 626 1 82 704... (4 Replies)
Discussion started by: yifangt
4 Replies
9. UNIX for Beginners Questions & Answers
Hi,
I tried filtering the records in a csv file using "awk" command listed below.
awk -F"~" '$4 ~ /Active/{print }' inputfile > outputfile
The output always has all the entries.
The same command worked for different users from one of the forum links.
content of file I was... (3 Replies)
Discussion started by: sunilmudikonda
3 Replies
10. UNIX for Beginners Questions & Answers
I have a csv file as shown below,
xop_thy 80 avr_njk 50 str_nyu 60
avr_irt 70 str_nhj 60 avr_ngt 50
str_tgt 80 xop_nmg 50 xop_nth 40
cyv_gty 40 cop_thl 40 vir_tyk 80
vir_plo 20 vir_thk 40 ijk_yuc 70
cop_thy 70 ijk_yuc 80 irt_hgt 80
I need to align/sort the csv file based... (7 Replies)
Discussion started by: dineshkumarsrk
7 Replies
LEARN ABOUT DEBIAN
slags2.f
slags2.f(3) LAPACK slags2.f(3)
NAME
slags2.f -
SYNOPSIS
Functions/Subroutines
subroutine slags2 (UPPER, A1, A2, A3, B1, B2, B3, CSU, SNU, CSV, SNV, CSQ, SNQ)
SLAGS2
Function/Subroutine Documentation
subroutine slags2 (logicalUPPER, realA1, realA2, realA3, realB1, realB2, realB3, realCSU, realSNU, realCSV, realSNV, realCSQ, realSNQ)
SLAGS2
Purpose:
SLAGS2 computes 2-by-2 orthogonal matrices U, V and Q, such
that if ( UPPER ) then
U**T *A*Q = U**T *( A1 A2 )*Q = ( x 0 )
( 0 A3 ) ( x x )
and
V**T*B*Q = V**T *( B1 B2 )*Q = ( x 0 )
( 0 B3 ) ( x x )
or if ( .NOT.UPPER ) then
U**T *A*Q = U**T *( A1 0 )*Q = ( x x )
( A2 A3 ) ( 0 x )
and
V**T*B*Q = V**T*( B1 0 )*Q = ( x x )
( B2 B3 ) ( 0 x )
The rows of the transformed A and B are parallel, where
U = ( CSU SNU ), V = ( CSV SNV ), Q = ( CSQ SNQ )
( -SNU CSU ) ( -SNV CSV ) ( -SNQ CSQ )
Z**T denotes the transpose of Z.
Parameters:
UPPER
UPPER is LOGICAL
= .TRUE.: the input matrices A and B are upper triangular.
= .FALSE.: the input matrices A and B are lower triangular.
A1
A1 is REAL
A2
A2 is REAL
A3
A3 is REAL
On entry, A1, A2 and A3 are elements of the input 2-by-2
upper (lower) triangular matrix A.
B1
B1 is REAL
B2
B2 is REAL
B3
B3 is REAL
On entry, B1, B2 and B3 are elements of the input 2-by-2
upper (lower) triangular matrix B.
CSU
CSU is REAL
SNU
SNU is REAL
The desired orthogonal matrix U.
CSV
CSV is REAL
SNV
SNV is REAL
The desired orthogonal matrix V.
CSQ
CSQ is REAL
SNQ
SNQ is REAL
The desired orthogonal matrix Q.
Author:
Univ. of Tennessee
Univ. of California Berkeley
Univ. of Colorado Denver
NAG Ltd.
Date:
November 2011
Definition at line 152 of file slags2.f.
Author
Generated automatically by Doxygen for LAPACK from the source code.
Version 3.4.1 Sun May 26 2013 slags2.f(3)