[ROOT] / doc / toc / ARCQuery / Class / QueryExpressionSelect

Execute , SyntaxHelp , TryCheckForExistenceOfKey


Selects which fields to include.

Note: QueryExpressionAll differs from QueryExpressionSelect 'SELECT *' regarding use of EntityMethodKeys.
The query 'Customer/All' will not include EntityMethodKeys, while 'Customer/SELECT *' would.

'SELECT *' can be used in connection with CompoundKey, like for instance
'Customer/SELECT *, CountP()' which will select all fields in addition to a new field calculated by NewKeyCountP.
See CompoundKey for the quite rich functionality offered (like traversion of entity relations for instance).

HINT: It is recommended to use 'AS' when using CompoundKey if subsequent QueryExpressions follows.
HINT: This will reduce parsing complexities because a complex field name may be unnecessary attempted evaluated as a CompoundKey.
HINT: Example: For 'Customer/SELECT Name, Order.OrderLine.Sum.Sum()/ORDER BY Order.OrderLine.Sum.Sum()', HINT: if the key 'Order.OrderLine.Sum.Sum()' does not exist for some Customer, it will be attempted reevaluated by the following QueryExpressionOrderBy
HINT: and may be misunderstood.
HINT: Doing instead 'Customer/SELECT Name, Order.OrderLine.Sum.Sum() AS OrderSum/ORDER BY OrderSum' will remove this possibility
HINT: (and be more readable also).

Note: The original key type is not necessarily preserved.
See hack in OrderAndReconstructKeys (called from ToHTMLSimpleSingle for details.

TODO: Add some functionality recognizing PriorityOrder, like
TODO: 'SELECT' which could select only from Important or lesser value.
TODO: Or 'SELECT WHERE PriorityOrder LEQ Important' (Using negative values for PriorityOrder is not very intuitive here).
TODO: or any other query against the property keys for the relevant entity class.

See SyntaxHelp.


ExecuteTransforms the given input collection into a resulting collection.
SyntaxHelpSELECT {field-1}, {field-2} ... {field-n}
TryCheckForExistenceOfKeyUsed by query expressions in order to catch wrong field names used or misspelling of field names.

Details

Generated 2024-04-20 04:55:04.560 UTC