# View: vendor_territory_restriction_snowflake_1

**View Name:** vendor_territory_restriction_snowflake_1
**Table Source:** `Derived from: Prod.Vw_Dim_Abacus_Ar_Vendor_Contract, Royalty_Accounting_Reporting, Royalty_Accounting_Reporting.Prod`
**File Path:** `vendor_territory_restriction_snowflake_1.view.lkml`

## Overview

- **File Size:** 1582 bytes
- **Lines of Code:** 60
- **Dimensions:** 3
- **Measures:** 2
- **Dimension Groups:** 0
- **Filters:** 0

## Comments & Notes

- measure: count_restrictions {
- label: "Count Restrictions (Labeled)"
- type: string

## Dimensions

| Name | Type |
|------|------|
| `primary_key` | string |
| `id` | number |
| `country_id` | number |

## Measures

| Name | Type |
|------|------|
| `count` | number |
| `list_restrictions` | string |

## Derived Table

```sql
sql: SELECT
        id,
        TRY_TO_NUMBER(a.value::string) AS country_id,
        CONCAT(id, country_id) AS primary_key
      FROM royalty_accounting_reporting.prod.vw_dim_abacus_ar_vendor_contract,
        LATERAL FLATTEN(INPUT => SPLIT(territory_carve_out, ',')) a
      WHERE primary_key IS NOT NULL
       ;;
```

