select single:
It fetches single record from the database, based on the condition you specified in the where clause
select upto:
Fetches first record if the condition specified in the where clause is satisfied, otherwise it doesn't fetch any record.
Login to rate this answer.
Select single * from table
It fetches single record from the database, based on the condition you specified in the where clause.
The 'SELECT SINGLE' statement selects the first row in the database that it finds that fulfills the 'WHERE' clause If this results in multiple records then only the first one will be returned and therefore may not be unique.
The 'SELECT .... UP TO 1 ROWS' statement is subtly different. The database selects all of the relevant records that are defined by the WHERE clause or lack of, applies any aggregate, ordering or grouping functions to them and then returns the first record of the resultant result set.
Where as select * from table up to 1 row
Fetches first record if the condition specified in the where clause is satisfied, otherwise it doesn't fetch any record.
Login to rate this answer.