mysql - What does a WHERE clause of "sql was here" mean? -


Does anyone help me understand or post any thoughts about this?

  sql  

I changed the table name, but besides that, any idea which the developer was trying to do here?

There is nothing else after that, this is exactly where the section is.

If (table.date_field = (choose the maximum (table2.exit_date) table 2 )) is zero, it will return 1 = 1 , which basically means that there is no section.

Now we see that filthy expression I can only assume that if "a = b" is not correct then that too is equal to zero, otherwise it seems that the first branch will always stay as it seems. That is trying to say "if the latest exit date is equal to date field, then select them, otherwise there is no space". However, I do not think that it will work at all. It actually looks in any way, each row will be selected.


Comments

Popular posts from this blog

oracle - The fastest way to check if some records in a database table? -

php - multilevel menu with multilevel array -

jQuery UI: Datepicker month format -