|
|
От: |
kavlad
|
http://www.wavesoft.ru |
| Дата: | 27.05.04 13:24 | ||
| Оценка: | |||
K_>SELECT FIRST("Id")
K_>FROM "tblMV"
K_>WHERE "Name" = :"Name"
K_>INTO :"Id"
K_>SELECT [TRANSACTION transaction]
[DISTINCT | ALL]
{* | val [, val …]}
[INTO :var [, :var …]]
FROM tableref [, tableref …]
[WHERE search_condition]
[GROUP BY col [COLLATE collation] [, col [COLLATE collation] …]
[HAVING search_condition]
[UNION [ALL] select_expr]
[PLAN plan_expr]
[ORDER BY order_list]
[ROWS value [TO upper_value] [BY step_value][PERCENT][WITH TIES]]
[FOR UPDATE [OF col [, col …]]];
ROWS value
[TO upper_value]
[BY step_value]
[PERCENT][WITH TIES]
• value is the total number of rows to return if used by itself
• value is the starting row number to return if used with TO
• value is the percent if used with PERCENT
• upper_value is the last row or highest percent to return
• If step_value = n, returns every nth row, or n percent rows
• PERCENT causes all previous ROWS values to be
interpreted as percents
• WITH TIES returns additional duplicate rows when the last
value in the ordered sequence is the same as values in
subsequent rows of the result set; must be used in
conjunction with ORDER BY
SELECT "Id"
FROM "tblMV"
WHERE "Name" = :"Name"
INTO :"Id"
ROWS 1