Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SqLite error near OUTPUT

Tags:

sqlite

output

I try to Update my table and return IDs of updated rows. here is the command:

UPDATE messages SET status = 2 OUTPUT inserted.ID WHERE status=1 and sender!=@person

But I get sqlite error for my OUTPUT clause. I use version 3 (the mono version for mobile)

like image 833
LittleMahdy Avatar asked Jun 11 '26 08:06

LittleMahdy


1 Answers

In SQLite, the UPDATE statement has no OUTPUT clause.

In an embedded database, there is no client/server communication overhead. Just get the IDs with a SELECT.

like image 103
CL. Avatar answered Jun 12 '26 23:06

CL.