# Boundary Master

## Overview

The Boundary Master sheet defines the hierarchical administrative areas of a ULB using multiple boundary levels.\
Each boundary level follows the naming pattern:

\<HIERARCHY\_NAME>\_\<LEVEL\_NAME>

#### Examples

* ADMIN123\_STATE
* ADMIN123\_CITY

Users only fill the hierarchy-level columns.\
The backend automatically generates metadata fields such as:

* CRS\_BOUNDARY\_CODE

This structure ensures accuracy, prevents duplication, and maintains a consistent administrative boundary tree.

Templates Provided:

* TEMPLATE – Auto-generated Boundary Master
* PREFILLED TEMPLATE – Prefilled Boundary Master Template
* Sample Generated Boundary Master: [Boundary Master Auto-Generate Sample Template](https://docs.google.com/spreadsheets/d/12onGILGc1XzIUfGlb2tYergvEzWV_GaU-9dHgFeJOrQ/edit?usp=sharing)

***

## Data Table

<table><thead><tr><th width="78.625">S.No.</th><th>STATE</th><th>CITY</th><th>ZONE</th><th>LOCALITY</th><th>BLOCK</th><th>Boundary Code</th><th>LAT</th><th>LONG</th></tr></thead><tbody><tr><td>1</td><td>Karnataka</td><td><br></td><td><br></td><td><br></td><td><br></td><td>(auto)</td><td>(optional)</td><td>(optional)</td></tr><tr><td>2</td><td>Karnataka</td><td>Bangalore</td><td><br></td><td><br></td><td><br></td><td>(auto)</td><td>(optional)</td><td>(optional)</td></tr><tr><td>3</td><td>Karnataka</td><td>Bangalore</td><td>Bangalore South</td><td><br></td><td><br></td><td>(auto)</td><td>(optional)</td><td>(optional)</td></tr><tr><td>4</td><td>Karnataka</td><td>Bangalore</td><td>Bangalore South</td><td>Koramangala</td><td><br></td><td>(auto)</td><td>(optional)</td><td>(optional)</td></tr><tr><td>5</td><td>Karnataka</td><td>Bangalore</td><td>Bangalore South</td><td>Koramangala</td><td>Block 1</td><td>(auto)</td><td>(optional)</td><td>(optional)</td></tr></tbody></table>

***

## Data Definition

<table><thead><tr><th width="74.58984375">Sr. No.</th><th>Column Name</th><th width="120.765625">Data Type</th><th width="110.1796875">Data Size</th><th>Mandatory?</th><th>Purpose / Description</th><th>User Input?</th><th>Excel Validation</th></tr></thead><tbody><tr><td>1</td><td>&#x3C;HIERARCHY_NAME>&#x3C;LEVEL_NAME></td><td>Text</td><td>256</td><td>Yes (as per hierarchy)</td><td>Boundary hierarchy: STATE → CITY → ZONE → LOCALITY → BLOCK</td><td>Yes</td><td>Alphabets &#x26; spaces only</td></tr><tr><td>2</td><td>CRS_BOUNDARY_CODE</td><td>Text</td><td>Auto</td><td>No</td><td>Unique boundary code generated by backend</td><td>No</td><td>Protected column (no input)</td></tr><tr><td>5</td><td>CRS_LAT</td><td>Decimal</td><td>Auto</td><td>No</td><td>The latitude of that Level</td><td>No</td><td>Decimal check (if filled)</td></tr><tr><td>6</td><td>CRS_LONG</td><td>Decimal</td><td>Auto</td><td>No</td><td>The Longitude of that level </td><td>No</td><td>Decimal check (if filled)</td></tr></tbody></table>

***

## Steps to Fill Data

1. Download the Boundary Master template.
2. Review the hierarchy columns (STATE, CITY, ZONE, LOCALITY, BLOCK).
3. Enter values starting from the highest level:
   1. Fill STATE first.
   2. Fill CITY only if STATE is filled.
   3. Fill ZONE only if CITY is filled.
   4. Fill LOCALITY only if ZONE is filled.
   5. Fill BLOCK only if LOCALITY is filled.
4. Ensure all hierarchy names contain only:
   1. Alphabets
   2. Spaces\
      No numbers or special characters.
5. Do not fill:
   1. Boundary Code - These are autogenerated by the backend.
6. After completing all rows, verify the sheet against validation rules.
7. Save and share for backend ingestion.

***

## Excel Validation Framework

This sheet includes two major validation rules:

### 1. Alphabetic Text Validation (User Input Columns)

Applied to hierarchy columns (STATE, CITY, ZONE, LOCALITY, BLOCK).

Rules:

* Only alphabets (A–Z) allowed
* Spaces permitted
* No numbers or symbols
* No mixed alphanumeric entries

### 2. Mandatory Hierarchy Rule

Each deeper level must follow the correct hierarchy order.

Examples:

* CITY cannot be filled if STATE is empty
* ZONE cannot be filled if CITY is empty
* LOCALITY cannot be filled if ZONE is empty
* BLOCK cannot be filled if LOCALITY is empty

***

## Backend-Generated Fields (Must Remain Empty)

The following fields must not be filled by users:

* CRS\_BOUNDARY\_CODE

Leaving these fields empty ensures correct backend processing and automatic generation.

### Backend Dynamic Generation Summary

The backend automatically generates the following:

#### Boundary Hierarchy Tree

Based on user-filled columns:

STATE → CITY → ZONE → LOCALITY → BLOCK

#### Boundary Code

Generated using:

* Hierarchy level
* Boundary name
* Backend rules

***

## Sample Rows (User-Filled Only)

| STATE     | CITY        | ZONE            | LOCALITY    | BLOCK       | Code                | LAT        | LONG       |
| --------- | ----------- | --------------- | ----------- | ----------- | ------------------- | ---------- | ---------- |
| Karnataka | <p><br></p> | <p><br></p>     | <p><br></p> | <p><br></p> | (filled by backend) | (optional) | (optional) |
| Karnataka | Bangalore   | <p><br></p>     | <p><br></p> | <p><br></p> | (filled by backend) | (optional) | (optional) |
| Karnataka | Bangalore   | Bangalore South | <p><br></p> | <p><br></p> | (filled by backend) | (optional) | (optional) |
| Karnataka | Bangalore   | Bangalore South | Koramangala | <p><br></p> | (filled by backend) | (optional) | (optional) |
| Karnataka | Bangalore   | Bangalore South | Koramangala | Block 1     | (filled by backend) | (optional) | (optional) |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.digit.org/complaints-management/complaints-resolution-v2.10/deploy/configure/master-data/master-data-templates/boundary-master.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
