Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Generate fixed length flat file from Oracle tables

Re: Generate fixed length flat file from Oracle tables

From: Mark D Powell <Mark.Powell_at_eds.com>
Date: 12 Aug 2005 06:32:04 -0700
Message-ID: <1123853524.707978.199510@g44g2000cwa.googlegroups.com>


I will add a couple of considerations to the task.

If any of the columns are defined larger than the allotted space on the output record you will want to use the substr function or the sqlplus option to truncate the column data rather than wrap long columns onto the next output line.

If any of the columns are numeric you can use to_char to zero fill from the right so that the numbers are right justified and do not contain spaces. You could use an SQLPlus column command also to control formatting of the column.

Date formatting is also handled by to_char.

HTH -- Mark D Powell -- Received on Fri Aug 12 2005 - 08:32:04 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US