| Reading Flat File with Header (2 Merged) [message #559485] |
Tue, 03 July 2012 10:19  |
lokimisc
Messages: 61 Registered: February 2008
|
Member |
|
|
Hi,
I'm working on loading the data from flat file into table and below given is the
validation condition given.
I checked the UTL_FILE build in package but not able to figure out, how to identify the column header in flat file.
1. Skip the header, if any. The header is the first record, and starts with '000'
2. Skip the trailer, if any. The Trailer is the last record, and starts with '999'
3. Log an error, but continue if a line exceeds 512 characters
4. Log an error, but continue if a line is blank
Appreciate any help on this.
Regards,
Lokesh
|
|
|
|
|
|
| Re: Reading Flat File with Header (2 Merged) [message #559496 is a reply to message #559485] |
Tue, 03 July 2012 10:52   |
 |
Michel Cadot
Messages: 54699 Registered: March 2007 Location: Nanterre, France, http://...
|
Senior Member Account Moderator |
|
|
A flat file has no header unless you define one.
How do you identify the header when you open the file in vi/notepad?
Do it in the same way in PL/SQL.
There is no difficulties in the specification you gave it is just basic PL/SQL you can do with the examples about UTL_fILE on the web and here.
Regards
Michel
[Updated on: Tue, 03 July 2012 10:52] Report message to a moderator
|
|
|
|
|
|
|
|
|
|