2. Select * from students where name='guo set' or name='king beautiful; This can detect two values
3. Select * from students where name='zhang' or 1=1 or '; This can find out all the values in the table,
So want to ask, why the first can only detect a value, the second is to find out two values, or should not be arbitrary as long as a condition is true, you can look it up? It should not be random draw a meet the conditions to query? In fact is not, then this or is how to choose the conditions to query the value of the
CodePudding user response:
1. Meet the condition 12. Meet the name=king beautiful or guo set
3. Meet 1=1 is true so find out all
CodePudding user response:
Got it, thank you, 111