I am new to SQLPLUS and am trying to format my output to a txt file. I am using SPOOL, however there is lot of other information that it spools to the file that I do not need. And also I am not able to make it to a certain column length.
Example; SELECT 'TABLEEMPL ', FIRST_NM, ID,'*' from mytable.
I want to have just the records on the file and nothing else. In other words my outfile should look like below. My first field has to be always 15 characters, Second be 20 characters, third 10 characters and last 1 character.
TABLEEMPL JOHN 111 *
TABLEEMPL CHRISTOPHER 121 *
TABLEEMPL AL 131 *