How to do INSERT IGNORE? #1095

Open
opened 2018-09-11 06:08:34 +00:00 by y0unghe · 3 comments
y0unghe commented 2018-09-11 06:08:34 +00:00 (Migrated from github.com)

I am trying to use a mysql query like below:

INSERT IGNORE INTO recent_adds (id,trackid,user) VALUES(NULL,...,...);

How to do that using xorm Insert function?

I am trying to use a mysql query like below: `INSERT IGNORE INTO recent_adds (id,trackid,user) VALUES(NULL,...,...);` How to do that using xorm Insert function?
Member

Oops, this function is not supported yet. But we're working on it?

Oops, this function is not supported yet. But we're working on it?

Add an Ignore() function?

Add an `Ignore() ` function?
Member

Sure, I think this function will setup a flag to determine ignore or not. But I'm afraid that it's not suitable for other db dialects. @lunny

Sure, I think this function will setup a flag to determine `ignore` or not. But I'm afraid that it's not suitable for other db dialects. @lunny
Sign in to join this conversation.
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: xorm/xorm#1095
No description provided.