Skip to content

SQL-186: OutputDocumentQueryProvider.PolicyOutputDocumentQuery

This statement is a read operation invoked through ORM (NHibernate LINQ). Executed by OutputDocumentQueryProvider.PolicyOutputDocumentQuery.

Classification

Field Value
SQL ID SQL-186
Operation type Read
Execution method ORM (NHibernate LINQ)
Database Oracle*
Schema [unqualified]**
Command type N/A (ORM-generated)
Business object OutputDocumentQueryProvider
Criteria property N/A — ORM
Lifecycle method PolicyOutputDocumentQuery

Tables

Table Access Columns used
policy_output_document SELECT output_document_seq_num, update_num, policy_period_eff_date, agency_seq_num, agent_num, agency_viewed_flag, agency_delivery_flag, agency_delete_date, create_user, create_date, update_user, update_date, release_date, hold_task_seq_num, task_user, source_key_text, ACCOUNT_NUM, policy_num, document_status_code

LINQ statement

Source: Data/SAIF.Data/Queries/OutputDocuments/OutputDocumentQueryProvider.cs:123.

private IQueryable<PolicyOutputDocument> PolicyOutputDocumentQuery()
{
    return Factory.GetRepository<PolicyOutputDocument>().Query();
}

Sample SQL

Inferred SQL: This SQL was inferred from the LINQ statement above and the NHibernate mappings. It is not concrete SQL from source code; NHibernate generates the executed statement at runtime, so aliases, column order, join syntax, and bind-parameter names may differ.

-- Inferred from LINQ (NHibernate mapping translation); not concrete SQL
-- Base query only: callers (e.g. lines 30, 60, 66, 82, 113, 118, 177, 190) compose
-- extension filters (Pending/Held/Released/AgencyViewable/ForPolicyOrAccount/...) on top of it
SELECT
  POD.output_document_seq_num,
  POD.update_num,
  POD.policy_period_eff_date,
  POD.agency_seq_num,
  POD.agent_num,
  POD.agency_viewed_flag,
  POD.agency_delivery_flag,
  POD.agency_delete_date,
  POD.create_user,
  POD.create_date,
  POD.update_user,
  POD.update_date,
  POD.release_date,
  POD.hold_task_seq_num,
  POD.task_user,
  POD.source_key_text,
  POD.ACCOUNT_NUM,
  POD.policy_num,
  POD.document_status_code
FROM policy_output_document POD

Translation notes: - The private helper returns IQueryable<PolicyOutputDocument>. On its own it has no WHERE clause, and it never executes as written. Each caller's extension methods append predicates (and possibly joins) before materialization. Those composed statements are not part of this SQL ID.

Operations and processes

Business rules

Sources

  • Data/SAIF.Data/Queries/OutputDocuments/OutputDocumentQueryProvider.cs:123