Page 1 of 1

Reading Fixed width file

Posted: Wed Aug 27, 2008 11:23 am
by deva
Hi I have one data file. it contain only one column with 27000.

I copied this file from desktop into unix. This file dosen't have delimiters and quote chars.

I am reading this file as Fixed width file. But I am getting error like ' columb unexpectedly terminated with error'.

Can any one sugget me how to read this file.

-Thanks in Advans

Posted: Wed Aug 27, 2008 11:36 am
by chulett
Binary or ASCII transfer? Only read it as fixed width if each record is always a consistent, fixed size. For that you need to ensure the Display Size is the actual size of each field. Otherwise just read it as one long varchar.

Posted: Wed Aug 27, 2008 10:02 pm
by tkbharani
Its because you need to FTP files from DOS to UNIX only in ASCII format , so that host transfers data consistently. If you have already transfered then use "dos2unix" command for converting DOS files to UNIX files.

Also while reading Fixed width make sure you are assigning exact column size and also take care of Display value. handling fixed width in server jobs and parallel jobs are some what different.