Maintain the information in the Semantic Analysis sub-node of the database view
The semantic analysis functionality for database views scans the query of the database view for references to Alfabet object classes and object class properties thereof. The Show Usage functionality in the context menu of object class properties evaluates the use of the object class property in configured reports on basis of the semantic analysis results.
The results of the semantic analysis are listed in a node Semantic Analysis beneath the node of each datase view in a hierarchical structure going down from object classes to object class properties to values of object class properties. The Name property of object classes and object class properties is used in the explorer.
If object class properties restrict the content of the database view via a WHERE clause definition in the underlying query, the values will be included into the semantic analysis for object class properties returning one of the following:
- The value of a standard Stereotype object class property.
The semantic analysis ignores value definitions including a wildcard and checks whether the object class stereotype name equals a stereotype name defined for the object class. Only existing object class stereotypes are listed.
- The value of a the Name of an object.
The semantic analysis ignores value definitions including a wildcard.
- A Boolean value.
- A value from an enumeration.
The semantic analysis ignores value definitions including a wildcard and checks whether the enumeration value is defined for the enumeration defined for the object class property. Only existing enumeration items are listed.
In addition, the semantic analysis maps all column names in the database view with the object class and object class property for which data is returned in the column. The results are listed in a sub-folder Aliases.
Scanning is done automatically after the query for the database view has been defined.
|
Please note the following:
|
The analysis scans both Alfabet queries and native SQL queries. It comprises object class properties referenced by any part of the query including joins and the object class properties of the type ReferenceArray which are included in native SQL queries via the PROPERTY column of the RELATIONS database table.
Alfabet queries and native SQL queries are handled differently:
- The semantic analysis for database views based on Alfabet queries is not editable.
Indicator and role definitions added via the show properties of the type Indicator or Role are not included into the semantic analysis results.
The REFSTR object class property of the FIND class of the Alfabet Alfabet query is added as object class property to the semantic analysis.
- Native SQL queries can be very complex and in some cases, the scanning mechanism may not find all relevant object classes and object class properties. Therefore, the solution designer can add missing information to the semantic analysis via the Add Properties option in the context menu of the Semantic Analysis node. Object class property values included in the semantic analysis are ReadOnly and excluded from editing. The semantic analysis is executed each time the native SQL query of the database view is changed. The manually-added semantic analysis results will be left unchanged during a subsequent semantic analysis.
Information about object classes and object class properties may be missing in the analysis for one of the following reasons:
- The query definition is incorrect. For example an object class or object class property name may have been added with a typo. It is recommended to check the query definition for correctness if the semantic analysis is missing or incomplete.
- Native SQL queries can be very complex and the scanning mechanism for semantic analysis may fail to identify object class or object class property specification.
If the semantic analysis of a correct native SQL query is incomplete, missing information can be added manually to complete the analysis: