Skip to content

SQL-001: Max PA auditor ID + 1

Retrieves MAX(PA_AUDITOR_ID) + 1 from PA_AUDITOR to generate the next available auditor identifier before inserting a new auditor record. This library uses a MAX+1 pattern rather than an Oracle sequence for this table.

Classification

Field Value
SQL ID SQL-001
Operation type Sequence
Execution method Inline SQL
Database Oracle
Schema [unqualified]**
Command type Text
Business object clsAuditor
Criteria property CreateSQL
Lifecycle method BeforeCreate

Parameters

This statement has no bind parameters.

Tables

Table Access Columns used
PA_AUDITOR SELECT PA_AUDITOR_ID

Sample SQL

SELECT TO_NUMBER(MAX(PA_AUDITOR_ID)) + 1 FROM PA_AUDITOR

Operations and processes

Note: Statements marked with * were inferred from code structure, naming conventions, or contextual evidence where direct confirmation was not available in source artifacts. Statements marked with ** could not be confirmed; treat as unknown until verified.

Sources

  • Business\SAIF.Business.External.Users\clsAuditor.vb