October 8th, 2003, 11:10 PM
load data infile
how can i use load data infile to do the following
data file has 5 fields:
table has 4 columns
table colums = (a,b,c,e)
load data infile 'file.txt' into table 'this_table' (a,b,c,,e)
will not work ? is it posable to make it work ?
I want to skip the empty column in the text file.
On a Linux box....
Note: bcp is a microsoft program and will not run on Linux.
Last edited by deterset; November 4th, 2003 at 10:39 AM.
October 9th, 2003, 02:34 PM
You can use bcp to import the data and specify to skip a column by using a format file. See http://msdn.microsoft.com/library/de...p_bcp_61et.asp for the bcp utiltity. At the bottom of the page is a link that tells you how to make/use format files. Hope this helps
Up the Irons
What Would Jimi Do? Smash amps. Burn guitar. Take the groupies home.
"Death Before Dishonour, my Friends!!" - Bruce D ickinson, Iron Maiden Aug 20, 2005 @ OzzFest
Down with Sharon Osbourne
"I wouldn't hire a butcher to fix my car. I also wouldn't hire a marketing firm to build my website." - Nilpo