10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
We have a requirement of picking nth position value by using cut command. value would be delimited by any symbols. We have to pass delimited value and postition to get the value in a string.
ex.
echo "A,B,C,D,E" |cut -d "," -f3
echo "A|B|C|D|E"|cut -d "|" -f2
Kindly frame the... (5 Replies)
Discussion started by: KK230689
5 Replies
2. UNIX for Dummies Questions & Answers
How to split 2:6..5 in to separate columns (7 Replies)
Discussion started by: Nadela
7 Replies
3. Shell Programming and Scripting
Hi All,
I have a string with , delimiter
america,finland,netherlands
Now i want these values to be stored in file as below with newline character at end of each value
america
finland
netherlands
Regards
Prasad (3 Replies)
Discussion started by: krishna_gnv
3 Replies
4. Shell Programming and Scripting
Hi Folks,
We have a file that has null values but there are no delimiters. So all columns are considered as a single column.
Ex:
abc def 123
abcdef1234567
hijklmn7896545
Now from "a" till "3" all are considered as a single column from the first row.
Our requirement is like, we... (2 Replies)
Discussion started by: jayadanabalan
2 Replies
5. Shell Programming and Scripting
I have a file containing multiple values, some of them are pipe separated which are to be read as separate values and some of them are single value all are these need to store in variables.
I need to read this file which is an input to my script
Config.txt
file name, first path, second... (7 Replies)
Discussion started by: ketanraut
7 Replies
6. Shell Programming and Scripting
Hi,
I have a file which has many URLs delimited by space. Now i want them to move to separate files each one holding 10 URLs per file.
http://3276.e-printphoto.co.uk/guardian http://abdera.apache.org/ http://abdera.apache.org/docs/api/index.html
I have used the below code to arrange... (6 Replies)
Discussion started by: vel4ever
6 Replies
7. Shell Programming and Scripting
hi,
i want to PASTE two files, with a delimiter in between, using awk and pipe the output to another file. i am able to achive the reqirement using PASTE command. but it has a limitation of length till 511 bytes.
Example:
-------
File1:
----
sam
micheal
file2:
----
bosco... (11 Replies)
Discussion started by: mohammedsadath
11 Replies
8. Shell Programming and Scripting
Hello Gurus,
I need to create a file from a .csv file extracting specific columns only.
File structure is
Column1,Column2,Column3,Column4
abcd,1234,"asdf, tew,123",123456
efgh,234,asdf,654321
My output file should have
abcd,123456
efgh,654321
Can you pls help me with the code.
... (10 Replies)
Discussion started by: ritesh.bhawsar
10 Replies
9. Shell Programming and Scripting
Hi all,
I'm trying to split fields separated by multiple characters :
Here's the string :
"toto"||"ta|ta"||"titi"
Here's what I want :
"toto"||"ta|ta"
I tried several ways, but it seems that my delimiter || is not working :
echo "\"toto\"||\"ta|ta\"||\"titi\"" | awk 'BEGIN... (4 Replies)
Discussion started by: popawu
4 Replies
10. Shell Programming and Scripting
hi guys,
basically what i'm trying to do is fetching a set of columns from an oracle database like so...
my_row=`sqlplus -s user/pwd << EOF
set head off
select user_id, username from all_users where rownum = 1;
EOF`
echo $my_row
the code above returns...
1 ADSHOCKER
so then i... (3 Replies)
Discussion started by: adshocker
3 Replies