drizzle-discuss team mailing list archive
Mailing list archive
Where clause with non-Boolean
during the testing, found that Where clause is accepting non-booleans.
select * from tablename where 1;
select * from tablename where columnname;
in other planets it is illegal. and citizens uses loopholes like:
create table x as select * from y where 1=2;
to get a empty table x with same structure as y.
Don't know it is MySQL ism or expected behaviour.
i noticed it because a typo like this :
delete from emp where id-2;
cleaned up my table. :(