For Programmers: Free Programming Magazines  


Home > Archive > PHP SQL > August 2004 > Re: using AUTO_INCREMENT with LOAD DATA INFILE









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: using AUTO_INCREMENT with LOAD DATA INFILE
Barand

2004-08-18, 3:57 pm

> LOAD DATA [LOW_PRIORITY | CONCURRENT] [LOCAL] INFILE
'file_name.txt'
> [REPLACE | IGNORE]
> INTO TABLE tbl_name
> [FIELDS
> [TERMINATED BY 't']
> [[OPTIONALLY] ENCLOSED BY '']
> [ESCAPED BY '' ]
>

]
> [LINES TERMINATED BY 'n']
> [IGNORE number LINES]
>

[(col_name,...)][/QUOTE]

1 ) If you just have the name and address data (no
id) just load those
and specify the column names you are loading.

2 ) you
can specify if you have used quotes withe ENCLOSED BY bit.

hth

Barand

http://members.aol.com/barryaandrew...agridguide.html easy
data tables
- and more

----------------------------------------
The post originated from
PHP Freaks:
----------------------------------------
http://www.phpfreaks.com
http://www.phpfreaks.com/forums


Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com