How to implement insert ignore unique rows only? #180
-
My crawler grabs links from each page and before insert, do lot of search queries to make sure that new link will be unique in database. Also it's spam I think it could be optimized, thoughts, instead of search request for each link, do something like:
And make CRC32 of URL as the document ID - just to simply ignore and not insert on 'primary key' already exist. it is possible with |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Manticore doesn't support If you want |
Beta Was this translation helpful? Give feedback.
Manticore doesn't support
INSERT IGNORE
, but it does supportREPLACE
- https://github.com/manticoresoftware/manticoresearch-php/blob/master/docs/usage.md#replaceIf you want
INSERT IGNORE
, you can ignore an error due to a duplicate document in your app.