---
title: "SQL-007: Insert deny-self-registration row"
summary: Inserts a new deny-self-registration block-list entry into EXT_USER_DENY_SELF_REG.
status: draft
owner: <owner>
last_reviewed: 2026-07-24
library: SAIF.Business.External.Users
reference_type: package
---

# SQL-007: Insert deny-self-registration row

Inserts a new block-list entry into `EXT_USER_DENY_SELF_REG`, preventing self-registration for the specified user-type/customer-group pair, as governed by [BR-EU-02](../business-rules.md#br-eu-02-deny-self-registration-block-list).

## Classification

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

## Parameters

| Parameter | Direction | Type | Max length | Description |
| --- | --- | --- | --- | --- |
| `:SourceSystemGroupID` | Input | String | 30 | Customer group ID (composite key part 1). |
| `:UserTypeCode` | Input | String | 5 | User type code (composite key part 2). |
| `:CustomerRequested` | Input | String | 1 | Customer-requested flag. |
| `:Reason` | Input | String | 200 | Free-text reason for the block. |
| `:CreateUser` | Input | String | 30 | Username creating the record. |
| `:CreateDate` | Input | DateTime | N/A | Record creation timestamp. |
| `:UpdateUser` | Input | String | 30 | Username of last update. |
| `:UpdateDate` | Input | DateTime | N/A | Last update timestamp. |
| `:UpdateNum` | Input | Decimal | N/A | Optimistic-concurrency counter. |

## Tables

| Table | Access | Columns used |
| --- | --- | --- |
| [EXT_USER_DENY_SELF_REG](../database-tables.md#ext_user_deny_self_reg) | INSERT | `CUSTOMER_GROUP_ID`, `EXT_USER_TYPE_CODE`, `CUSTOMER_REQUESTED_FLAG`, `REASON_TXT`, `CREATE_USER`, `CREATE_DATE`, `UPDATE_USER`, `UPDATE_DATE`, `UPDATE_NUM` |

## Sample SQL

```sql
INSERT INTO EXT_USER_DENY_SELF_REG (
    CUSTOMER_GROUP_ID, EXT_USER_TYPE_CODE, CUSTOMER_REQUESTED_FLAG, REASON_TXT,
    CREATE_USER, CREATE_DATE, UPDATE_USER, UPDATE_DATE, UPDATE_NUM
)
VALUES (
    :SourceSystemGroupID, :UserTypeCode, :CustomerRequested, :Reason,
    :CreateUser, :CreateDate, :UpdateUser, :UpdateDate, :UpdateNum
)
```

## Operations and processes
- [Deny self-registration check](../operations/deny-self-registration-check.md)

## Business rules
- [BR-EU-02: Deny-self-registration block-list](../business-rules.md#br-eu-02-deny-self-registration-block-list)

> **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.External.Users\clsUserDenySelfRegistration.vb`
