0

Can we use the command "LIMIT" in place of "BETWEEN", following "WHERE" to retrieve some records of particular range?

As in both we retrieve records only we have to care in LIMIT, where offset of first record is taken as zero.

5th Mar 2018, 1:33 PM
Zeeshan zakaria
Zeeshan zakaria - avatar
1 Odpowiedź
0
no ...LIMIT is basically to retrieve a subset of the expected set of records...suppose you want to display all employees whose salary is in range of 10000 and 25000 you use Between operator...your employees table might have 100 records and this query might retreive say some 15 records...but if you want to see only few of them say 5 records then before ending the query you put limit 5 ...that retrives only 5 of those 15 records
5th Mar 2018, 2:10 PM
srividya