I have to create a windows batch file which will read an input file and remove "double quotes" from each line of the file.
For eg.If input file name is abcd.csv and contents is :
Then the batch file should remove "" from the start and end of the line and output file should be:
Plz help
Thanks
A Triva question.
What is the easy way to remove the double quotes in the file in the following format.
"asdfa","fdgh","qwer"
tr -d '\"' <filename >newfilename
mv newfilename oldfilename
This need to be handled in a script. Any better way to do this. Will sed be more effecient?
One... (3 Replies)
I want to remove the comma which is present within the double quoted string. All other commas which is present outside double quotes should be present.
Input : a,b,"cc,dd,ee",f,ii,"jj,kk",mmm
output : a,b,"ccddee",f,ii,"jjkk",mmm (3 Replies)
Hi All,
I have a tab delimited file where each of the strings have double quotes.
The problem is that I have records which are in the following format:
"TEXAS" ""HOUSTON"" "123" "" "2625-39-39"
""MAINE"" "" "456" "I" "3737-39-82"
I would have to output... (3 Replies)
I have one file a.txt as below.
a.txt
"aaas","111111","ewwee32e","deee333",
"aaas","111111","ewwee32e","deee333",
"aaas","111111","ewwee32e","deee333",
"aaas","111111","ewwee32e","deee333",
I want to write a script to process a.txt and want the output as below in different file as below -... (2 Replies)
Hi Unix Gurus..
I am new to Unix. Please help me. The file I am getting is as follows:
Input File
"2011-07-06 03:53:23","0","I","NOT SET ",,,,"123985","SAW CUT CONCRETE SLAB 20"THICK",,"98.57","","EACH","N"
"2011-07-06 03:53:23","0","I","NOT SET ",,,,"204312","ARMAFLEX-1 3/8 X... (2 Replies)
Hi,
I am little new to forum and new on unix side. I have a small issue below:
I am reading a file that has 5 columns something like below.
col1,col2,col3,col4,col5
Some records are having double quoted values something like below:
"value1","value2","value3","value4","value5"
I need... (8 Replies)
i have data as below
123,"paul phiri",paul@yahoo.com,"po.box 23, BT","Eco Bank,Blantyre,Malawi"
i need an output to be
123,"paul phiri",paul@yahoo.com,"po.box 23 BT","Eco Bank Blantyre Malawi" (5 Replies)
Hi All,
I'm unable to load the data using sql loader where there are double quotes within the double quotes As these are optionally enclosed by double quotes.
Sample Data :
"221100",138.00,"D","0019/1477","44012075","49938","49938/15043000","Television - 22" Refurbished - Airwave","Supply... (6 Replies)
I have file with are delimited by pipe(|) symbol, I wanted those to be removed except the ones which are enclosed in double quotes.
If your quote file is:
|Life is |Beautiful"|"Indeed life |is beautiful too|"|"But unix is fun| is not"|"
It should return:
Life is Beautiful"|"Indeed life is... (1 Reply)
Hi ALL,
file data like :
test.csv
a,b,"c,d"
my awk version is 4.0.2 ,if i am using the below code is working fine.
awk -vFPAT='(*)|("+")' -vOFS="," '{print $3}' test.csv
if the awk version is 3.1.7 is not working . Could you please help me on this one.
output should be : "c,d" (6 Replies)
Discussion started by: bmk123
6 Replies
LEARN ABOUT BSD
rnews
RNEWS(1) General Commands Manual RNEWS(1)NAME
rnews - receive news from a UUCP connection
SYNOPSIS
rnews [ -h host ] [ -v ] [ -U ] [ -N ] [ -S master ] [ input ]
DESCRIPTION
Rnews reads messages typically queued by a UUCP newsfeed and sends them to the local InterNetNews server. The message is read from the
specified input file, or standard input if no input is named.
When sent over UUCP, Usenet articles are typically joined in a single batch to reduce the UUCP overhead. Batches can also be compressed,
to reduce the communication time. If a message does not start with a number sign (``#'') and an exclamation point, then the entire input
is taken as a single news article. If it does start with with those two characters, then the first line is read and interpreted as a batch
command.
If the command is ``#! rnews nnn'' where nnn is a number, then the next nnn bytes (starting with the next line) are read as a news article.
If the command is ``#! cunbatch'' then the rest of input is fed to the compress(1) program with the ``-d'' flag to uncompress it, and the
output of this pipe is read as rnews's input. This is for historical compatibility -- there is no program named cunbatch. A compressed
batch will start with a ``#! cunbatch'' line, then contain a series of articles separated by ``#! rnews nnn'' lines.
If the command is any other word, then rnews will try to execute a program with that name in the directory /usr/lib/news/rnews. The batch
will be fed into the program's standard input, and the standard output will be read back as input into rnews.
If rnews detects any problems with an article such as a missing header, or an unintelligible reply from the server, it will save a copy of
the article in the /var/spool/news/in.coming/bad directory.
OPTIONS -S If the ``-S'' flag is used, then rnews will connect to the specified host. If the flag is not used, it will try to connect to the
server by opening a Unix-domain stream connection. If that fails, it will try to open a TCP connection to the default remote
server.
-U If the server is not available, the message is spooled into a new file created in the /var/spool/news/in.coming directory. The
``-U'' flag may be used to send all spooled messages to the server once it becomes available again, and can be invoked regularly by
cron(8).
-N Normally, if unpacking the input fails it is re-spooled to /var/spool/news/in.coming for another attempt later. If the ``-N'' flag
is used then no such re-spooling is done and rnews exits with status value ``9'' to indicate this.
-v If the ``-v'' flag is used, it will print a notice of all errors on the standard error, naming the input file (if known) and print-
ing the first few characters of the input. Errors are always logged through syslog(3).
-h If the ``-h'' flag is given, or failing that, the enviroment variable UU_MACHINE is set, then rnews will log the Message-ID, and
host, for each article offered to the server via syslog(3). Logging will only be done if the value is not an empty string.
BUGS
Rnews cannot process articles that have embedded 's in them.
HISTORY
Written by Rich $alz <rsalz@uunet.uu.net> for InterNetNews. This is revision 1.23, dated 1996/11/08.
SEE ALSO innd(8).
RNEWS(1)