Let me know how to delete the null line using sqlldr, ctl. And I wanna know how to remove the last two line of files. There are null lines in tail, that is the last 1~2 line. Plus I cannot know the last line number. wait to reply
Asked
Active
Viewed 415 times
0
-
Can you please show us what exactly you wanna do. show us that part of the file as sample please – El.Hum Jan 06 '19 at 07:45
-
Will you know the number of blank lines at the end of the file? – Gary_W Jan 07 '19 at 17:42
-
what OS are you using to run sqlldr in? – Gary_W Jan 07 '19 at 17:48
1 Answers
0
You need to either pre-process the file and remove blank lines before running sqlldr via a wrapper script, or more common, just load all rows from the file into a staging table, then call a PL/SQL script from there to load into the main table.
Pre-processing alters the main file so that is usually not a good idea unless of course you make an archive copy first.
Using a staging table is more common as that way all rows from the file are available and you can select the rows you want, transforming, validating, etc the data on the way into the main table.

Gary_W
- 9,933
- 1
- 22
- 40