view: ownership_delivery_territories { sql_table_name: ORCHARD_APP_REPORTING_V2.PROD_NR_OWNERSHIP_DELIVERY_NEIGHBOURING_RIGHTS_OWNERSHIP_DELIVERY.TERRITORIES ;; # ========================================================================= # 1. PRIMARY KEYS & STRUCTURAL LINKS # ========================================================================= dimension: unique_id { primary_key: yes type: number sql: ${TABLE}.ID ;; label: "Territory Assignment ID" description: "The primary unique immutable surrogate key identifier for this specific scoping row." } dimension: territory { type: string sql: ${TABLE}.TERRITORY ;; label: "Assigned Territory Code" description: "Standard market country geographical designation code." } # ========================================================================= # 2. SYSTEM METADATA TIMESTAMPS (Hidden) # ========================================================================= dimension: _fivetran_deleted { type: yesno sql: ${TABLE}._FIVETRAN_DELETED ;; group_label: "System Metadata" hidden: yes } dimension_group: _fivetran_synced { type: time timeframes: [raw, date] datatype: timestamp sql: ${TABLE}._FIVETRAN_SYNCED ;; group_label: "System Metadata" hidden: yes } # ========================================================================= # 3. MEASURES # ========================================================================= measure: unique_territory_record_count { type: count description: "The count of territory mapping boundaries logged within the system configuration." } }