That is unfortunate as catting a file into a pipe and then reading it from stdin loses its file name, making it impossible to add its parts to the csv output file.
In a normal *nix setup, I'd propose something like (untested!)
I have a file as follows:
1,"This is field 2",3,4,5
2,"This is field 2 it can contain one , comma",3,4,5
3,"This is field 2 it also, can, contain, more",3,4,5
4,"This is field 2 without extra commas",3,4,5
and i pass this through to awk:
awk -F, ' {
if (... (3 Replies)
Hi Guys,
I need to write a script, that exports the "moz_places" table of the "places.sqlite"-file (firefox browser history) into a csv-file. That part works. After the export, my csv looks like this:
...
4429;http://www.sqlite.org/sqlite.html;"Command Line Shell For... (11 Replies)
I have 2 files pipe delimted and want to merge them based on a key
e.g file 1
123$aaa$yyy$zzz
345$xab$yzy$zyz
456$sss$ttt$foo
799$aaa$ggg$dee
file 2
123$hhh
345$ddd
456$xxx
888$zzz
so if the key is the first field, and the result should be the common key between file 1 and 2 (6 Replies)
I need to read data from a file called "test.csv" through shell script where the file contains values like name,price,descriptor etc. There are rows where descriptor (& in some rows name) are written as string & other characters like "car_+" OR "bike*" etc where it should contains strings like... (3 Replies)
I need to
1.Open a csv
2.Process the csv i.e. Modify 2 column in the csv.
To modify the column the value needs to be passed to a pl/sql function and the return value should be updated
For eg:
If column 2 E,then E will be passed in database function
which will return Employee.
3. Write a... (5 Replies)
Hi Friends,
I want to convert a csv file into a ordinary .txt file. I am able to convert but I want the output to look as shown below in the .txt file
table findhost=
{
{"xyz","abc"},
{"rxz","mmz"},
{"vrr","nnz"},
}
default={"NONE"}
My current perl script
#!/usr/bin/env perl... (12 Replies)
Hi, I would like to change my CSV file by adding " and : and moving some of the information around. the CSV file looks as follows:
501254424;500440257;PE PACKS;300467279;PREP;;276476070;655031001867176;Two Block;Olga;25/12/2015 00:00:00;Olga
I would like to move the field 7 to the front "... (13 Replies)
Hello Gentlemen,
Finding difficulties to play with my Input files:confused: . Your guidance will certainly help as always.
After converting to csv file from XLSM file, I am getting some extra ""(double quote) characters which I want to terminate inside shell script and process it further.
... (6 Replies)
Hello all,
I have searched high and low for a solution to this, many have come really close but not quite what I'm after.
I have 2 files. One contains GUID's, for example:
8121E002-96FE-4C9C-BC5A-6AFF20DACECD
84468F30-F3B7-418B-81F0-0908E80792BF
A second file, contains a path to the... (8 Replies)
wk on csv files
Hi I have two csv files
1 ) keys.csv with data as below
XX1,offsite
XX2,offsite
XX8,none
XX3,offsite
XX4,onsite
XX7,none
XX5,onsite
XX6,onsite
XX15,none
2) source.csv file with data like
1,0123,ppp,XX1
2,0122,sss,XX2
3,1239,yyy,XX8
4,567,kkk,XX5 (2 Replies)