mkosmosports Posted December 11, 2007 Share Posted December 11, 2007 Hello, When issuing update or insert sql statements using PDO->execute is there anyway of knowing whether any rows were actually affected? Also, is there anyway execute can return a FALSE boolean? (it says on the www.php.net/pdo site it can, but how?) Thanks. mkosmosports Link to comment https://forums.phpfreaks.com/topic/81221-knowing-if-pdo-execute-affected-any-rows/ Share on other sites More sharing options...
trq Posted December 11, 2007 Share Posted December 11, 2007 rowCount returns the number of effected rows. Also, is there anyway execute can return a FALSE boolean? (it says on the www.php.net/pdo site it can, but how?) I'm not sure what you mean exactly. It does return true on success or false on failure. Link to comment https://forums.phpfreaks.com/topic/81221-knowing-if-pdo-execute-affected-any-rows/#findComment-412265 Share on other sites More sharing options...
mkosmosports Posted December 11, 2007 Author Share Posted December 11, 2007 Hey Thorpe, Thanks for your answer. This is exactly what Im looking for. Nevermind my other question. Thanks again. Link to comment https://forums.phpfreaks.com/topic/81221-knowing-if-pdo-execute-affected-any-rows/#findComment-412295 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.