---
title: "SQL-022: Policy waiver count check"
summary: Count waiver records to detect waiver existence.
status: draft
owner: SAIF Doc Gen
last_reviewed: 2026-07-31
library: SAIF.Business.View.Policy
reference_type: package
---

# SQL-022: Policy waiver count check

`clsPolicyData` uses this call to answer whether a policy carries any third-party waiver of subrogation. The procedure returns a count, and the caller treats any non-zero result as a yes.

## Classification

| Field | Value |
| --- | --- |
| **SQL ID** | SQL-022 |
| **Operation type** | Read |
| **Execution method** | Stored procedure |
| **Database** | Oracle |
| **Schema** | `[unqualified]`** |
| **Command type** | StoredProcedure |
| **Business object** | `clsPolicyData` |
| **Criteria property** | `HasWaiverSQL` |
| **Lifecycle method** | `RetrieveHasWaiver` |

## Parameters

| Parameter | Direction | Type | Max length | Description |
| --- | --- | --- | --- | --- |
| `:PolicyNum` | Input | Decimal | not specified | Policy number being checked for third-party waiver records. |
| `:WaiverCount` | ReturnValue | Decimal | N/A | Count of `WAIVER_DETAIL` rows; any non-zero value is treated as `True` by the caller. |

## Tables

No table is referenced directly in the .NET source. The tables read by the procedure body reside in the Oracle database and are described under [Pk82033_ThirdParty](../procedures/pk82033_thirdparty.md).

## Sample SQL

```sql
-- Stored procedure call (procedure body resides in the Oracle database - WCIS_DBA.Pk82033_ThirdParty)
CALL Pk82033_ThirdParty.get_policy_waiver_count(
  PolicyNum => :PolicyNum)
-- returns WaiverCount (return-value output parameter)
```

## Operations and processes

- [Check waiver existence](../operations/check-waiver-existence.md)

> **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.View.Policy/clsPolicyData.vb`
