Bug #7121 LOAD_DATA_INFILE replaces when necessary
Submitted: 9 Dec 2004 8:54 Modified: 9 Dec 2004 8:57
Reporter: Mickael Besson Email Updates:
Status: Open Impact on me:
None 
Category:MySQL Server: Command-line Clients Severity:S4 (Feature request)
Version:4.1.7 OS:Microsoft Windows (Windows NT4)
Assigned to: CPU Architecture:Any
Triage: D5 (Feature request)

[9 Dec 2004 8:54] Mickael Besson
Description:
I've to create a batch program which refresh, each day, datas in DB of employees. 
For information, others DB have FK on this one. And lots of requests use DB of employees, through many applications. 

When using LOAD_DATA_INFILE command on DB 'EMPLOYEES', datas can be replaced by option 'REPLACE'. 

The problem is that it rewrites all lines without verifying if they have been really modify, on one field other multiple fields (ex: email, adress, aso). So, a lot of query in cache which use this DB are deleted, and applications lose a little bit of performance. 

Could you add another parameter to this command in order to replace lines when datas have been updated, and only in this case.
FaNx

How to repeat:
 

Suggested fix:
- compare line per line (id1=id2) the value of each field
- ....
[9 Dec 2004 8:57] Mickael Besson
Sorry, it's a new feature request and not a bug