My query below being called from sqlplus is returning lot of spaces in the end of each value, how can I remove it?
See example below: * I substituted the values with x>
The simplest way is to concatenate the columns with the commas in between, rather than using colsep:
colsep
select process_id ||','|| x1 ||','|| x2 ...
Note that you only have the comma in the concatenation strong, not between the columns. You end up with a single column in the reult.