10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
I have a comma separated file which contains data like;
File header:
ID_WVR,SAK_WVR_SVC,DSC_WVR_WVC,SAK_PROCEDURE,CODES,CDE_PROC_MOD ,CDE_PROC_MOD_2 ,CDE_PROC_MOD_3
File Detail:
AMR,5100,Total Services,305,D0120,,,
AMR,5101,Periodic Services,40702,H2011,U1,,
AMR,5112,Day... (4 Replies)
Discussion started by: jnrohit2k
4 Replies
2. Shell Programming and Scripting
Hello,
Could you please help me how to search the string in a file, and when found; change the existing line to uppercase in command line?
I tried:
?whichcommand? -A "EXT" fileA | awk '{print tolower($0)}' | tee fileB
tr command simply converts entire file to uppercase but this is not what... (4 Replies)
Discussion started by: baris35
4 Replies
3. Shell Programming and Scripting
Hi Froum.
I have tried in vain to find a solution for this problem - I'm trying to replace any double quotes within a quoted string with a single quote, leaving everything else as is.
I have the following data:
Before:
... (32 Replies)
Discussion started by: pchang
32 Replies
4. Shell Programming and Scripting
Hi ,
I have below input file
1.order number is useful.
2.vendor_id is produced.
3.the vandor name is "malawar".
I want output file like
1. order number is useful.
2. vendor_id is produced.
3. the vandor name is VmalawarV.
in input file line number 1.order number there is no... (4 Replies)
Discussion started by: vinothsekark
4 Replies
5. Shell Programming and Scripting
Hi every body!
I wrote script on Fedora (bash shell) to check whether a tring enter from user console is start with a uppercase/lowercase letter or a digit. But with this script i have some problem when I enter from character from 'b' to 'z' --> result is uppercase. This code look like ok but i... (9 Replies)
Discussion started by: nguyendu0102
9 Replies
6. UNIX for Dummies Questions & Answers
Hi,
I have variable inside shell script - from_item.
from_item = 40.1'1/16
i have to first find out whether FROM_ITEM contains single quote(').
If yes, then that need to be replace with two quotes ('').
How to do it inside shell script? Please note that inside shell script........ (4 Replies)
Discussion started by: yogichavan
4 Replies
7. Shell Programming and Scripting
Hi,
How do I replace the charachters = '*' to = '^' using Sed commands.
As I have several * in the script, thus I have to replace the single quotes too.
Please let me know any solution.
I have tried the escape character backslash '\' but it doesnt help.
sed "s/= \'*\'/=... (2 Replies)
Discussion started by: prachifun
2 Replies
8. Shell Programming and Scripting
Could you please help in unix scripting for below scenario...
In my input file, there might be a chance of having a string ( Ex:"99999") after 5th double quote for each record. I need to replace it with a space.
Ex : Input :
"abcdef","12345","99999","0986"... (3 Replies)
Discussion started by: vsairam
3 Replies
9. UNIX for Dummies Questions & Answers
i have this piece of small code that checks for *.CSV files.
NUMFILES=`ls -1 *.CSV | wc -l`
for filename in $(ls -1 *.CSV)
do
...
done
it works only if the files has an uppercase of *.CSV extension. however, when there is a file of the same type but has lowercase *.csv... (1 Reply)
Discussion started by: wtolentino
1 Replies
10. Shell Programming and Scripting
I've got a text file which has " marks where it there should be ' marks. I tried to do it with sed, but it won't allow me to escape the ' mark.
Here's what I tried to do:
sed 's/"/\\'/g' file.txt
How can this be done?
Thanks (3 Replies)
Discussion started by: CraigMoore
3 Replies