Guidelines for Authoring Business Object Queries
Follow these guidelines to define aliases, map fields, document parameters, and review BQL query definitions.
Use the following guidelines when you create or review a Business Object Query.
- Use meaningful source aliases and named-select names. Avoid generic names such
as
subQuery1. - Map every field needed for joins, filters, grouping, and output in
fieldAliases. - Document each parameter's type, required or optional status, default value, and allowed values.
- Aggregate detailed records to the intended output grain before joining them to other result sets.
- Define output aliases and deterministic ordering. Do not retain test-only
limits, such as
FETCH FIRST 1 ROWS ONLY, in production queries. - Use only functions and SQL features confirmed for the target Business Object Query deployment.
Query Review Checklist
- Confirm that the
SELECTcolumn order matches thereturnentries. For a defined query, check each entry's response name andrefortype. - Confirm that each business object and view in
viewQueriesis correct. Map every field used by the query infieldAliases.