Does the data to be replaced have a unique record key if not the data will just be appended.
From the mysql documentation.
The REPLACE and IGNORE keywords control handling of input records that duplicate existing records on unique key values. If you specify REPLACE, new rows replace existing rows that have the same unique key value. If you specify IGNORE, input rows that duplicate an existing row on a unique key value are skipped. If you don't specify either option, an error occurs when a duplicate key value is found, and the rest of the text file is ignored
Does the data completely replace the data in the database? if it does why not just flush the database first.
Mark.