PDA

View Full Version : FlatFileItemReader



Yann
Mar 7th, 2008, 10:52 AM
Hello

Is it possible to read a flat file where my data are delimited by position in the line ? whithout separator ?
Ex :
- data1 : betwen 0 and 5
- data2 : betwen 6 and 10
- ....
If yes, can you send me a small example ?

Thank you !
Yann

lucasward
Mar 7th, 2008, 11:25 AM
Yes, we call this fixed length formatting. There is a sample job called FixedLengthImportJob that shows this functionality. Essentially, you simply use a FixedLengthLineTokenizer in your FlatFileItemReader, configuring the columns as ranges.

I'm hoping to finish the reference documentation for the major ItemReaders and Writers today, look for it to be pushed out next week. (sorry it wasn't already there)

Yann
Mar 10th, 2008, 04:39 AM
Ok
Thank you :)

newbie_9
Dec 23rd, 2010, 12:14 PM
Hey,

Where is the sample job code available? or is any of the source code for the examples referenced in the documentation available?

Thanks.

bwawok
Dec 23rd, 2010, 12:21 PM
All the source code is in the big zip download.