Page 1 of 1

mistake: BUG: Wrong Feedback for DELETE (fake join)

Posted: Tue 26 Jun 2012 11:02
by michabbb
[dbforge version: 5.0.76]

dear support,

when doing a delete with a query ( on mysql 5.5.8 ) like this:

DELETE
FROM
aaaaa, tmp_tmp_008
USING
aaaaa
INNER JOIN tmp_tmp_008
USING (xxx_id)
WHERE
tmp_tmp_008.xxx_id IS NOT NULL
AND
aaaaa.db_changed IS NULL;

i get the result:

SQL24.sql: 61290 rows deleted [4,499s]

but the real number of rows deleted is half that number: 30645

at some point, the number of deleted rows gets doubled, that is very very confusing
and i got very frustrated because i thought i delete too much or my query is wrong ;)

so please fix this in your next update! ;-)

thank you!
michael

Re: BUG: Wrong Feedback for DELETE (fake join)

Posted: Tue 26 Jun 2012 12:53
by alexa
Please note that you're deleting records from two tables but not from one.

Please let us know if that was the problem.

Re: mistake: BUG: Wrong Feedback for DELETE (fake join)

Posted: Tue 26 Jun 2012 18:10
by michabbb
you´r right, sorry, didn´t notice that this query also deletes the records from the other table ;(

thank you!

Re: mistake: BUG: Wrong Feedback for DELETE (fake join)

Posted: Wed 27 Jun 2012 09:25
by alexa
Please let us know should other questions arise.