Jump to content

Archived

This topic is now archived and is closed to further replies.

blanktarget

importing a text file

Recommended Posts

I can\'t get this text fle imported. I have over one hundreditems I want into one field, the table has two fields, an auto_increm id field and the other field which is varchar data. I get all manner of errors inserting them.

:cry:

$sql= \"INSERT INTO table (\'column_2\') VALUES (\'item_1,\')\";

\"INSERT INTO table (\'column_2\') VALUES (\'item_2,)\";

etc 100 times.

 

if (@mysql_query($sql)) {

echo(\"<h4 align=\'center\'>Your listing has been added</h4><br>\");

} else {

echo(\"<h4>Error the adding the listing: \" .

mysql_error() . \"</h4>\");

}

 

what is wrong?

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.