Thread: Fixed column format data

Fixed column format data

From
Greg Stark
Date:
Is there any facility to import a text file that's in fixed column format? The
copy command seems to use a delimiter only. I have no delimiter, but have
specified column widths.

Are the only ways to either do many insert queries, or preprocess the file
into a delimited file and then copy?

--
greg

Re: Fixed column format data

From
Shridhar Daithankar
Date:
On Thursday 06 November 2003 21:00, Greg Stark wrote:
> Is there any facility to import a text file that's in fixed column format?
> The copy command seems to use a delimiter only. I have no delimiter, but
> have specified column widths.
>
> Are the only ways to either do many insert queries, or preprocess the file
> into a delimited file and then copy?

Well, a simple C program would do the job, isn't it? Of course there could be
some scripting solutions but I don't have anything offhand..

 Shridhar