Gabriel PREDA schrieb:
Try:

ALTER TABLE `tbl_name` DISABLE KEYS;
-- now insert in the TXT file
ALTER TABLE `tbl_name` ENABLE KEYS;


I think this is what you were looking for !


That would have been a possibility. I did it this way now:

...
echo "set sql_log_bin=0; set foreign_key_checks=0; use $db; load data infile \"$txtfilename\" into table $tablename fields enclosed by '\"';"| $MYSQL_BIN $MYSQL_CONNECT
...

Script performs several checks before this statement and puts the txtfile in the appropriate directory.

Regards
Dominik

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to