Skip to content

SQL-020: Retrieve group or chapter contact

SQL-020 retrieve group or chapter contact in support of clsContact.

Classification

Field Value
SQL ID SQL-020
Operation type Read
Execution method Inline SQL via BOF data portal
Database Oracle
Schema [unqualified]**
Command type Text
Business object clsContact
Criteria property RetrieveSQL (+ const RETRIEVE_CONTACT)
Lifecycle method BeforeRetrieve / AfterRetrieve

Parameters

Parameter Direction Type Max length Description
:GroupAssociationCode In String not specified Criteria property — bound once per UNION branch.
:GroupChapterCode In String not specified Criteria property — bound only in the second UNION branch; the first branch returns the group-level contact where GROUP_CHAPTER_CODE IS NULL.

Tables

Table Access Columns used
GROUP_ASSOCIATION_CONTACT SELECT GROUP_ASSOCIATION_CODE, CONTACT_NAME, CREATE_USER_NAME, UPDATE_USER_NAME, CREATE_DATE, UPDATE_DATE, GROUP_CHAPTER_CODE, GROUP_CONTACT_TITLE_DESCR, GROUP_CONTACT_PHONE, GROUP_CONTACT_800_PHONE, GROUP_CONTACT_FAX_NUM, GROUP_CONTACT_EMAIL_ADDR

Sample SQL

Select
  GROUP_ASSOCIATION_CONTACT.GROUP_ASSOCIATION_CODE as GroupAssociationCode,
  GROUP_ASSOCIATION_CONTACT.CONTACT_NAME as ContactName,
  GROUP_ASSOCIATION_CONTACT.CREATE_USER_NAME as CreateUserName,
  GROUP_ASSOCIATION_CONTACT.UPDATE_USER_NAME as UpdateUserName,
  GROUP_ASSOCIATION_CONTACT.CREATE_DATE as CreateDate,
  GROUP_ASSOCIATION_CONTACT.UPDATE_DATE as UpdateDate,
  GROUP_ASSOCIATION_CONTACT.GROUP_CHAPTER_CODE as GroupChapterCode,
  GROUP_ASSOCIATION_CONTACT.GROUP_CONTACT_TITLE_DESCR as GroupContactTitleDescr,
  GROUP_ASSOCIATION_CONTACT.GROUP_CONTACT_PHONE as GroupContactPhone,
  GROUP_ASSOCIATION_CONTACT.GROUP_CONTACT_800_PHONE as GroupContact800Phone,
  GROUP_ASSOCIATION_CONTACT.GROUP_CONTACT_FAX_NUM as GroupContactFaxNum,
  GROUP_ASSOCIATION_CONTACT.GROUP_CONTACT_EMAIL_ADDR as GroupContactEmailAddr
From
  GROUP_ASSOCIATION_CONTACT
Where
  GROUP_ASSOCIATION_CONTACT.GROUP_ASSOCIATION_CODE = :GroupAssociationCode
  AND GROUP_ASSOCIATION_CONTACT.GROUP_CHAPTER_CODE IS NULL
UNION
Select
  GROUP_ASSOCIATION_CONTACT.GROUP_ASSOCIATION_CODE as GroupAssociationCode,
  GROUP_ASSOCIATION_CONTACT.CONTACT_NAME as ContactName,
  GROUP_ASSOCIATION_CONTACT.CREATE_USER_NAME as CreateUserName,
  GROUP_ASSOCIATION_CONTACT.UPDATE_USER_NAME as UpdateUserName,
  GROUP_ASSOCIATION_CONTACT.CREATE_DATE as CreateDate,
  GROUP_ASSOCIATION_CONTACT.UPDATE_DATE as UpdateDate,
  GROUP_ASSOCIATION_CONTACT.GROUP_CHAPTER_CODE as GroupChapterCode,
  GROUP_ASSOCIATION_CONTACT.GROUP_CONTACT_TITLE_DESCR as GroupContactTitleDescr,
  GROUP_ASSOCIATION_CONTACT.GROUP_CONTACT_PHONE as GroupContactPhone,
  GROUP_ASSOCIATION_CONTACT.GROUP_CONTACT_800_PHONE as GroupContact800Phone,
  GROUP_ASSOCIATION_CONTACT.GROUP_CONTACT_FAX_NUM as GroupContactFaxNum,
  GROUP_ASSOCIATION_CONTACT.GROUP_CONTACT_EMAIL_ADDR as GroupContactEmailAddr
From
  GROUP_ASSOCIATION_CONTACT
WHERE
  GROUP_ASSOCIATION_CONTACT.GROUP_ASSOCIATION_CODE = :GroupAssociationCode
  AND GROUP_ASSOCIATION_CONTACT.GROUP_CHAPTER_CODE = :GroupChapterCode

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.Policy.Group\clsContact.vb