SELECT clause

SELECT [ALLOWED] [DISTINCT] [TOP <Count>]
     <Selection field list>

The query description begins with the required SELECT keyword.

The ALLOWED keyword means that the query selects only records allowed by the current user access rights.

This keyword can only be included in the top level SELECT clause and is applied throughout the entire query, including the nested queries.

If you do not specify this keyword and the query selects records for which the user does not have rights, an error occurs.

Using the DISTINCT keyword, you can indicate that duplicate rows should not be included in the result.

You can use logical expressions in this clause.

See also:
           Quantity Function

The TOP <Count> clause allows you to set the maximum number of rows in the query result. The first rows will be shown (according to the ordering rules for query results). <Count> is always an integer.

The query text includes a selection field list after the SELECT keyword (and the following qualifying words: ALLOWED, DISTINCT and TOP).

1C:Enterprise Developer's Community