Page is a not externally linkable
wrightee - 10:27 am on Nov 4, 2011 (gmt 0)
Got it:
1: Load CSV into tmp table with extra columns for normalisation (e.g. keyword_id,campaign_id)
2: INSERT IGNORE INTO tbl_keywords (keyword) SELECT DISTINCT (keyword) FROM tmp
3: UPDATE tmp.keyword_id SET keyword_id= (SELECT.. etc)
And finally populate tbl_performance with new data in tmp, using normalised columns instead of raw data and truncate the tmp table.
All seems to work very fast.