Can I ignore rows when Loading Data Into a table?
LOAD XML LOCAL INF开发者_StackOverflow社区ILE 'c:/users/ryan/desktop/2.xml'
REPLACE INTO TABLE product
ROWS IDENTIFIED BY '<product>'
I want to only update 2 rows based on my XML file. Can I ignore specific rows of the table?
You can ignore specified number of first rows, e.g. - 'IGNORE 10 LINES'; otherwise, load all rows into another table, then write UPDATE or INSERT...SELECT query to change rows you need (there should be keys to specify these rows).
精彩评论