Please do not consider the previous email. I found my error.
mysqlimport is behaving exactly as expected.
Regards, Clodoaldo Pinto
On Sat, 29 Jan 2005 15:53:48 -0200, Clodoaldo Pinto
<clodoaldo.pinto@stripped> wrote:
> I need to update a table with mysqlimport.
>
> I would like to update the table lines with the same unique key and
> mantain the other lines untouched.
>
> When I use "mysqlimport --replace" the table lines with the same
> unique key are updated but the others are deleted.
>
> Is it the expected behavior? How to avoid the other lines being deleted?
>
> Using FC3. The server version is 4.0.23-standard and the mysqlimport
> version is Ver 3.4 Distrib 4.0.23.
>
> The command line:
>
> /usr/local/bin/mysqlimport --replace --local
> --fields-terminated-by=';' --fields-optionally-enclosed-by='"'
> --lines-terminated-by='\n' --fields-escaped-by='' --host=localhost
> --user=***** --password=***** --verbose dbname /path/to/txt/Temp.txt
> >>import.log 2>>importErr.log
>
> import.log:
>
> Connecting to localhost
> Selecting database dbname
> Loading data from LOCAL file: /path/to/txt/Temp.txt into Temp
> dbname.Temp: Records: 2415 Deleted: 0 Skipped: 0 Warnings: 0
> Disconnecting from localhost
>
> importErr.log is empty.
>
> Table structure:
> CREATE TABLE Temp (
> team int(10) unsigned NOT NULL default '0',
> points int(11) NOT NULL default '0',
> wus int(11) NOT NULL default '0',
> day date NOT NULL default '0000-00-00',
> PRIMARY KEY (team, day)
> ) TYPE=MyISAM;
>
> Regards, Clodoaldo Pinto
>