0
Where clause is similar to limit offset
the purpose of limit is to exclude certain result so can we use where clause to limit such data is it performace based to use limit rather then using where clause
1 Odpowiedź
+ 4
Although these two may seem similar in functionality, but they are meant for different purposes.
LIMIT is used solely to specify limit on how many record should be returned in a result set.
WHERE is used to define filter specifica used to decide whether a record should or should not be included in the result set. WHERE evaluates fields' value, expression, or function return value, and based on the specification given, decide whether or not a record fits the specification and be included in the result set.
LIMIT and WHERE clause can be used independently or together, depending on the necessity.
Hth, cmiiw