Home » SQL & PL/SQL » SQL & PL/SQL » Fixed Width Flat file via Oracle table (11g,win 7)
|
|
|
|
|
|
|
Re: Fixed Width Flat file via Oracle table [message #656194 is a reply to message #655909] |
Tue, 27 September 2016 15:42  |
Bill B
Messages: 1971 Registered: December 2004
|
Senior Member |
|
|
Littlefoot wrote on Fri, 16 September 2016 01:16I'd use RPAD function and add as many spaces as needed to each of these column values. You might also need to nest RPAD with SUBSTR, just in case if some column value length is, actually, larger than the ones you specified.
Actually, you will not need substr. RPAD takes care of truncation if the string is longer then the length specified.
test>select rpad('1234567890',5,' ') from dual;
RPAD(
-----
12345
|
|
|
Goto Forum:
Current Time: Sun Jun 29 15:47:34 CDT 2025
|