I am working for one mysql db query performance improvement task and i faced below one query where the "where clause is 1=1".
my question is, what is different in term of performance for executing time of below two db query
Select * from Table1 where 1=1
Select * from Table1
nos of records : 159954 for table1 for one client
nos of records :2452798 for table1 for second client.
and in some cases, this table is joined with another table with same where clause 1=1
.
can mysql query compiler optimize this query while execution ?
Version of MySQL Server 5.1