MySQL Forums
Forum List  »  Newbie

Re: Strange result from DELETE query - can anyone explain?!
Posted by: Jay Alverson
Date: March 21, 2009 07:14AM

If zero = false then everything else has to be true in their world ;)

mysql> select -1 is true;
| -1 is true |
|          1 |
1 row in set (0.00 sec)

Right VB and VBScript offer 0=False, -1=True, though I can't say I've tested every logical permutation.

I'm used to the MySQL logic, since another language I use is based on C. There you have things like

IF 1
; Stuff to do IF true


; stuff to do WHILE true

It's handy in that language when dealing with COM objects which are either 0 or a number that's a reference to the object/property etc.


Thanks, Jay

Options: ReplyQuote

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.