Resolved: About min() and limit
Why we used Min() and why we didn't use" between " Instead of limit ?
I need a explain
1 answers ( 1 marked as helpful)
Hi Mido!
Thanks for reaching out.
We use it to extract just one department number. If we didn't, we would have obtained all of them, thus getting more records than we need. We use LIMIT to restrict the number of rows returned, while BETWEEN filters rows based on a range of values. They're not interchangeable because LIMIT controls quantity, and BETWEEN defines conditions.
Hope this helps.
Best,
Tsvetelin
Thanks for reaching out.
We use it to extract just one department number. If we didn't, we would have obtained all of them, thus getting more records than we need. We use LIMIT to restrict the number of rows returned, while BETWEEN filters rows based on a range of values. They're not interchangeable because LIMIT controls quantity, and BETWEEN defines conditions.
Hope this helps.
Best,
Tsvetelin