08-18-2014
While you have included everything on one line, this is really 2 records
Each records starts with "INSERT INTO....VALUE...
It is actually already comma delimited if your strip out the heading of each line. How many tables are in your sql file?
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I am trying to write a script to convert csv files into SQL format.
What I am missing is:
1. handling of the first row and create it as a insert into format
2. better handling of any other row, and create a line with the data. *The while read line needs a better work.
I thought of using awk.
... (1 Reply)
Discussion started by: saariko
1 Replies
2. Shell Programming and Scripting
Hi,
Can any one please help me in converting a tab delimited file in .csv file.
Records in my file are similar to mentioned below:
DET 001 0201 AC032508970 01478E1X8
DET 002 0202 AC032508971 01478E1X8
Could any one please suggest me what approach would be more suitable for this or if... (5 Replies)
Discussion started by: dtidke
5 Replies
3. Shell Programming and Scripting
Hi
I have a excel file in unix machine and have to convert it into a .csv file.I have to do this from a unix script.How do we do this?
Thanks
Abhinav (3 Replies)
Discussion started by: akashtcs
3 Replies
4. Shell Programming and Scripting
Hi ,
I used the below script to get the sql data into csv file using unix scripting.
I m getting the output into an output file but the output file is not displayed in a separe columns .
#!/bin/ksh
export FILE_PATH=/maav/home/xyz/abc/
rm $FILE_PATH/sample.csv
sqlplus -s... (2 Replies)
Discussion started by: Nareshp
2 Replies
5. Shell Programming and Scripting
hi
Can anybody help me with converting such structure into csv file for windows :
BAT_ID ID_num CVS_LINE A_SEG SKILL_TO A_CUSTOMER_TYPE
--------- ---------- --------------------------------- ---------- ------------------ -----------
14-MAY-11 777752 ... (4 Replies)
Discussion started by: kvok
4 Replies
6. Shell Programming and Scripting
Hi, could some help me convert CSV file (with double quoted strings) to pipe delimited file:
here you go with the same data:
1,Friends,"$3.99 per 1,000 listings",8158here " 1,000 listings " should be a single field.
Thanks,
Ram (8 Replies)
Discussion started by: Ram.Math
8 Replies
7. Shell Programming and Scripting
Hi ,
I have a simple text file with contents as below:
12345678900 971,76 4234560890
22345678900 5971,72 5234560990
32345678900 71,12 6234560190
the new csv-file should be like:
Column1;Column2;Column3;Column4;Column5
123456;78900;971,76;423456;0890... (9 Replies)
Discussion started by: FreddyDaKing
9 Replies
8. Shell Programming and Scripting
Hi all,
I need to find a way to convert excel file into csv or a text file in linux command. The reason is I have hundreds of files to convert. Another complication is the I need to delete the first 5 lines of the excel file before conversion.
so for instance
input.xls
description of... (6 Replies)
Discussion started by: johnkim0806
6 Replies
9. UNIX for Advanced & Expert Users
we have a CSV which i need to convert to XML using Perl or Unix shell scripting.
I was able to build this XML in oracle database. However, SQL/XML query is running for long time. Hence, I'm considering to write a Perl or shell script to generate this XML file. Basically need to build this XML... (3 Replies)
Discussion started by: laknar
3 Replies
10. Shell Programming and Scripting
I have input data looks like this which is a part of a csv file
7,1265,76548,"0102:04"
8,1266,76545,"0112:04"
I need to make the output data should look like this and the output data will be part of text file:
7|1265000 |7654899 |A|
8|12660000 |76545999 |B|
The logic behind the... (6 Replies)
Discussion started by: RJG
6 Replies
LEARN ABOUT DEBIAN
cvm-sql
cvm-sql(7) Miscellaneous Information Manual cvm-sql(7)
NAME
cvm-sql - CVM SQL Framework
QUERY SUBSTITUTION
$VAR and ${VAR} are replaced with the quoted value of the environment variable named VAR. Use the second form when VAR contains anything
other than alpha-numeric or underscore (_) characters. Do not include quotes in the query. The variables account and domain contain the
account and domain names given by the CVM client. $$ is replaced with a single dollar sign.
QUERY RESULTS
The query must produce the following fields exactly in order. All required fields must not be null or empty.
1. Password, encrypted with crypt(3) (required)
2. Actual account name (required)
3. User ID (integer) (required)
4. Group ID (integer) (required)
5. Directory (required)
6. Real name (optional)
7. Login shell (optional)
8. Group name (optional)
9. Domain name (optional)
10. System account name (optional)
11. System account directory (optional)
12. Mailbox path (optional)
DEFAULT QUERY
SELECT password, username, userid, groupid, directory, realname, shell, groupname, domain, sys_username, sys_directory FROM accounts WHERE
username=$account AND domain=$domain
SEE ALSO
cvm-mysql(8), cvm-pgsql(8), cvm-pwfile(8), cvm-qmail(8), cvm-unix(8), cvm-vmailmgr(8), cvm-benchclient(8), cvm-checkpassword(8), cvm-test-
client(8)
http://untroubled.org/cvm/cvm.html
cvm-sql(7)