Is it possible to get id of affected rows in MySQL?
Posted
by user198729
on Stack Overflow
See other posts from Stack Overflow
or by user198729
Published on 2010-03-12T07:46:37Z
Indexed on
2010/03/12
7:47 UTC
Read the original article
Hit count: 154
I'm using pdo
to do this :
update tags set cnt=cnt-1 where name in ?
delete from news_tag where news_id=? and tag_id in (select id from tags where name in ?)
But if I can get affected rows' id
,the subquery is not needed.
© Stack Overflow or respective owner