Skip to content

SQL-004: Insert IMAGE_AFFILIATION row

This statement inserts a new row into the IMAGE_AFFILIATION table, recording the association between an image (by IMAGE_SEQ_NUM) and an affiliated entity (by AFFILIATION_IMAGE_SEQ_NUM). The CREATE_DATE is set using Oracle sysdate.

Classification

Field Value
SQL ID SQL-004
Operation type Create
Execution method Inline SQL
Database Oracle
Schema [unqualified]**
Command type Text**
Business object clsImageAffiliation
Criteria property InsertSQL
Lifecycle method BeforeInsert

Parameters

Parameter Direction Type Max length Description
:AffiliationImageSeqNum Input [not specified]** N/A The affiliation image sequence number.
:CreateUser Input [not specified]** 30 User ID of the record creator.
:ImageAffiliationSeqNum Input [not specified]** N/A Primary key for the IMAGE_AFFILIATION row (from SQL-001).
:ImageSeqNum Input [not specified]** N/A Foreign key to the IMAGE row.

Tables

Table Access Columns used
IMAGE_AFFILIATION INSERT AFFILIATION_IMAGE_SEQ_NUM, CREATE_DATE, CREATE_USER, IMAGE_AFFILIATION_SEQ_NUM, IMAGE_SEQ_NUM

Sample SQL

Insert into IMAGE_AFFILIATION (
    AFFILIATION_IMAGE_SEQ_NUM,
    CREATE_DATE,
    CREATE_USER,
    IMAGE_AFFILIATION_SEQ_NUM,
    IMAGE_SEQ_NUM
) Values (
    :AffiliationImageSeqNum,
    sysdate,
    :CreateUser,
    :ImageAffiliationSeqNum,
    :ImageSeqNum
)

Operations and processes

Note: Statements marked with ** could not be confirmed; treat as unknown until verified.

Sources

  • Business\SAIF.Business.Imaging\clsImageAffiliation.vb