Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: generating flat files with no blank caracters
Mark D Powell a écrit :
> Raphael Duenas <raf_at_srd.fr> wrote in message news:<3BD6641B.5C73A57B_at_srd.fr>...
> > Ed Prochak a écrit :
> >
> > > Please give more details. SQL Loader can ignore blanks easily. so what
> > > really is the problem??
> >
> > An example of a line to load :
> > " 9| 10| 2| 4|"
> >
> > it's the look of my flat file, so when i want to load this, sqloader tell me
> > that the numbers colums are not valid ORA-1722 not a valid number.
> > I want only unload a part or the totality of a table for load it into an other
> > database.
> >
> > >
> > >
> > > Raphael Duenas wrote:
> > > >
> > > > Hi,
> > > >
> > > > I want to generate a flat file so i can use it for partial loads on over
> > > > databases, but when i do it with sqlplus, number's columns are completed
> > > > with blank caracters and the file can't be use with sqloader. So how i
> > > > should do to get a no blank car file.
> > > >
> > > > thanks
> > > >
> > > > Raphaël
> > > > Dijon/FRANCE
>
Sure !
LOAD DATA
INFILE noy_menu.unl
INTO TABLE noy_menu REPLACE
FIELDS TERMINATED BY '|'
TRAILING NULLCOLS
(
C_PLAT
, C_DESTINATION , C_REPAS , C_REGIME , D_MENU DATE "DD/MM/YYYY" , T_PLAT , N_POSITION , B_EDITION , C_PLATEAU
noy_menu :
19| 1| 3| 31|24/10/01|V| 99| 19| 1| 3| 14|24/10/01|V| 99| 19| 1| 3| 15|24/10/01|V| 99| >