Hi! I am using solaris os. from solaris im logging into sql plus. my database is oracle 9i. i am spooling the output of my query into a file. i want in .csv format so that i can copy it into excel. can any1 help me out. my query is like. select name,id,location from employee;
A:
hi! i have found a way out of it. we can use concatenation here. select name,id,location from employee; gives us 2 different columns, but not in a csv format. what i did is
select name||','||id||','||location from employee; we get the output in a csv format. it has just concatenated the output with commas(,).
randeepsp
2010-03-29 06:50:23
Your solution works unless you have commas located in your data. In those instances you will need to double quote the fields.
Dan
2010-03-29 07:26:10