MySQL Notes - Questions and Answers

where 1 = 1 and where 1 = 0 are What does this mean?

where 1 = 1 condition is always True, the role is: a method of constructing the multi-criteria query, if the conditions are not met, SQL will not go wrong.
where 1 = 0 condition is always false, action is: the query does not return the result only returns the table structure. It can be used to quickly build the table

Guess you like

Origin www.cnblogs.com/junzifeng/p/11830785.html