Using Predefined Configuration Data
Query text can contain the following predefined configuration data:
- enumerations values;
- predefined data of:
- catalogs;
- charts of characteristic types;
- charts of accounts;
- charts of calculation types;
- empty references;
- business process route point values.
The query text can also contain the system enumeration values which can be assigned to fields in the database tables: RecordTypeAccumulation, AccountType and RecordTypeAccounting.
Predefined configuration data and system enumeration values can be referenced in the queries using literal of the functional VALUE type:
VALUE(<ExpressionValue>)
For system enumerations, <ExpressionValue> looks as follows:
<SystemEnumerationName>.<Value>
Valid names of system enumerations are listed above. The list of allowable values is given in each description.
For predefined configuration data, <ExpressionValue> looks as follows:
<PredefinedValueType>.<MetadataObjectName>.<Value>
<PredefinedValueType> can be:
- Catalog;
- ChartOfCharacteristicTypes;
- ChartOfAccounts;
- ChartOfCalculationTypes;
- Enum.
For <MetadataObjectName> the name of metadata object name indicated in the Designer is specified.
For enumerations defined in the configuration, <Value> is specified as the name of corresponding metadata object type EnumerationValue. For other types of predefined values, <Value> is specified as a predefined data entity name indicated in the Designer, or EmptyRef to specify an empty reference.
For the business process route points, <ExpressionValue> looks as follows:
BusinessProcess.<MetadateObjectName>.RoutePoint.<RoutePointName>.
Some fragments of queries explaining the use of predefined data in queries are given below:
WHERE City = VALUE(Catalog.Cities.Moscow)
WHERE City = VALUE(Catalog.Cities.EmptyRef)
WHERE ProductType = VALUE(Enumeration.ProductTypes.Service)
WHERE RecordType = VALUE(RecordTypeAccumulation.Receipt)
WHERE RoutePoint = VALUE(BusinessProcess.BusinessProcess1.RoutePoint.Action1)