About SBM–Processed SQL

When you use a conditional expression in your SQL statement (not pass-through SQL with the @ modifier), SBM attempts to process the Advanced SQL condition.

When you provide a conditional expression in the statement, SBM scans the conditional expression you enter and performs certain transformations. Consider the Severity field, a commonly used selection field. It has selections such as Critical, High, Medium, and Low. A field in the Issues table named Severity stores the severity of each item. However, the Severity field does not actually contain the words "critical," "high," and so on as its data. Instead, it stores numeric values that refer to the Selections table that contains the name of each selection. The application scans the conditional expression you enter and makes the appropriate numeric substitutions before sending the SQL statement to the database.

Note: The results from the SBM SQL processing might not always be correct SQL, so you must test the report by carefully examining any error conditions from the DBMS and adjust the report condition appropriately.

When you use processed conditions, use the displayed field names so that you will not need to know the database names of the fields. The processed conditional expressions can use Date/Time keywords, such as now and startof_thismonth.

Note: To convert the field names in the condition to SQL, SBM parses through the condition trying to change names before giving it to the DBMS. SQL functions and aggregates may not work correctly because of this.

Related Topics

Examples of SBM–Processed SQL

Using SBM–Processed SQL for Multi-Selection, Multi-Group, and Multi-User Fields

Examples of Using LIKE and NOT LIKE Operators in SBM–Processed SQL

About Pass-Through SQL

Common SQL Operators