---
title: "SQL-002: AddressVerificationQueryProvider.GetAddressVerificationRequests"
summary: Read operation for `AddressVerificationQueryProvider.GetAddressVerificationRequests`
status: draft
owner: SAIF.Core documentation team
last_reviewed: 2026-09-24
library: SAIF.Data
reference_type: package
---

# SQL-002: AddressVerificationQueryProvider.GetAddressVerificationRequests

This statement is a read operation invoked through ORM (NHibernate LINQ). Executed by `AddressVerificationQueryProvider.GetAddressVerificationRequests`.

## Classification

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

## Parameters

| Parameter | Direction | Type | Max length | Description |
| --- | --- | --- | --- | --- |
| `addressVerificationSeqNum` | Input | long | N/A | Method argument of `AddressVerificationQueryProvider.GetAddressVerificationRequests` bound into the ORM expression; NHibernate generates the bind variable at runtime |

## Tables

| Table | Access | Columns used |
| --- | --- | --- |
| [ADDRESS_VERIFICATION_REQUEST](../database-tables.md#address_verification_request) | SELECT | ADDR_VERIFICATION_REQ_SEQ_NUM, UPDATE_NUM, REQUEST_DATE, STATUS_CODE, RESPONSE_DATE, ADDRESS_LINE1, ADDRESS_LINE2, CITY_NAME, STATE_CODE, ZIP_CODE, ZIP_CODE_EXT, UPDATE_DATE, UPDATE_USER, UNMATCHED_ADDRESS_FLAG, MULTIPLE_MATCH_FLAG, AUTO_UPDATE_BYPASS_DATE, VERIFIED_ADDRESS_SEQ_NUM |

## LINQ statement

Source: `Data/SAIF.Data/Queries/AddressVerification/AddressVerificationQueryProvider.cs:42`. The repository is a class field initialised from `Factory.GetRepository<AddressVerificationRequest>().Query()` at `Data/SAIF.Data/Queries/AddressVerification/AddressVerificationQueryProvider.cs:19`.

```csharp
return addressVerificationRepository.SingleOrDefault(x =>  x.Id == addressVerificationSeqNum
                                                           && x.VerifiedAddress  != null
                                                           && x.IsUnmatchedAddress == false
                                                           && x.IsMultipleMatch == false);
```

## 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.

```sql
-- Inferred from LINQ (NHibernate mapping translation); not concrete SQL
SELECT
  AVR.ADDR_VERIFICATION_REQ_SEQ_NUM,
  AVR.UPDATE_NUM,
  AVR.REQUEST_DATE,
  AVR.STATUS_CODE,
  AVR.RESPONSE_DATE,
  AVR.ADDRESS_LINE1,
  AVR.ADDRESS_LINE2,
  AVR.CITY_NAME,
  AVR.STATE_CODE,
  AVR.ZIP_CODE,
  AVR.ZIP_CODE_EXT,
  AVR.UPDATE_DATE,
  AVR.UPDATE_USER,
  AVR.UNMATCHED_ADDRESS_FLAG,
  AVR.MULTIPLE_MATCH_FLAG,
  AVR.AUTO_UPDATE_BYPASS_DATE,
  AVR.VERIFIED_ADDRESS_SEQ_NUM
FROM ADDRESS_VERIFICATION_REQUEST AVR
WHERE AVR.ADDR_VERIFICATION_REQ_SEQ_NUM = :addressVerificationSeqNum
  AND AVR.VERIFIED_ADDRESS_SEQ_NUM IS NOT NULL
  AND AVR.UNMATCHED_ADDRESS_FLAG = 'N'
  AND AVR.MULTIPLE_MATCH_FLAG = 'N'
-- NHibernate expects at most one row
```

Translation notes:
- `x.VerifiedAddress != null` is an FK null check, so it resolves to `AVR.VERIFIED_ADDRESS_SEQ_NUM IS NOT NULL` with no join; `VERIFIED_ADDRESS` is not accessed as a separate table.
- `== false` on the `YesNoType`-mapped `IsUnmatchedAddress` and `IsMultipleMatch` properties becomes `= 'N'`.

## Operations and processes

- [Other query providers](../operations/other-query-providers.md)


## Sources
- `Data/SAIF.Data/Queries/AddressVerification/AddressVerificationQueryProvider.cs:42`
