December 2019
Beginner to intermediate
770 pages
16h 14m
English
A query object allows you to define an object that can be used to retrieve data from a single table or from multiple tables by applying filters and joins between tables. The returned result is a single dataset.
You can create a query in AL by using the tquery snippet:
query Id MyQuery{ QueryType = Normal; elements { dataitem(DataItemName; SourceTableName) { column(ColumnName; SourceFieldName) { } filter(FilterName; SourceFieldName) { } } } var myInt: Integer; trigger OnBeforeOpen() begin end;}
As you can see, a query object has an elements section, and inside that section, you define a dataitem and its column elements that must be retrieved (the table fields to be included in the resulting dataset).
You can also ...
Read now
Unlock full access