2008年8月1日星期五

Re: [fw-db] Cardinality Violation - executing queries

ahh i had more than one column in the 'in' clause! That's fixed now and
generates working sql, but i am having trouble executing them - just this
section:

$db->beginTransaction();
try {
$result = $db->query($deleteQuery);
$result->execute();
$db->query($insertQuery);
$result->execute();
$db->commit();
}catch (Exception $e){
echo $e->getMessage();
$db->rollBack();
}
do i need to explicitly execute the query? It seems to delete the rows (the
first query) but doesn't perform the second one, as the table is missing the
rows - they are not being replaced by the second query. I am having trouble
understanding the return value from $result::execute. How can i see if it
was successful or not?
--
View this message in context: http://www.nabble.com/Cardinality-Violation---executing-queries-tp18772524p18773013.html
Sent from the Zend DB mailing list archive at Nabble.com.

没有评论: