Search Results as_territory_groups_all




Overview

The AS_TERRITORY_GROUPS_ALL table is a core data structure within the Oracle E-Business Suite Sales Foundation module (AS). Its primary function is to define and store master records for territory groups, which are logical collections of sales territories used for hierarchical organization, reporting, and assignment rules. The table is owned by the OSM schema and is designed to support multi-organization access control through its "_ALL" suffix, meaning it contains data across all operating units when the relevant HR Security profile option is enabled. A critical point from the provided ETRM documentation is its status as "Obsolete." This indicates that while the table exists in versions 12.1.1 and 12.2.2, its associated functionality may be deprecated, and new implementations should utilize alternative, supported territory management features.

Key Information Stored

The table's structure centers on a unique territory group identifier and a name. The primary key is the AS_TERRITORY_GROUPS_PK constraint on the TERRITORY_GROUP_ID column, which holds the system-generated unique identifier for each group. A second unique constraint, AS_TERRITORY_GROUPS_UK, is enforced on the NAME column, ensuring no duplicate territory group names exist. While the specific metadata for other standard columns (e.g., CREATION_DATE, LAST_UPDATE_DATE, LAST_UPDATED_BY) is not listed in the excerpt, it is standard for EBS tables to include these WHO columns for auditing. The key data point stored is the relationship between a TERRITORY_GROUP_ID and its NAME.

Common Use Cases and Queries

Given its obsolete status, direct operational use in new customizations is discouraged. However, it remains relevant for historical data analysis, supporting legacy reports, and understanding existing data relationships. Common queries involve joining this table to its related territory tables to generate hierarchical lists or validate data integrity. A typical pattern is to retrieve all territory groups with their associated territories. Due to the obsolete nature, queries are often for diagnostic or migration purposes rather than active transaction processing.

SELECT tg.NAME AS TERRITORY_GROUP,
       t.NAME AS TERRITORY_NAME
FROM AS_TERRITORY_GROUPS_ALL tg,
     AS_TERRITORIES_ALL t
WHERE tg.TERRITORY_GROUP_ID = t.TERRITORY_GROUP_ID
ORDER BY tg.NAME, t.NAME;

Related Objects

The ETRM documentation explicitly defines the following foreign key relationships, where AS_TERRITORY_GROUPS_ALL is the parent table. These relationships are fundamental to the territory data model:

  • AS_TERRITORIES_ALL: This table references AS_TERRITORY_GROUPS_ALL via the column AS_TERRITORIES_ALL.TERRITORY_GROUP_ID. This links individual territories to their parent group.
  • AS_TERRITORY_TYPES_ALL: This table has two documented foreign key relationships referencing AS_TERRITORY_GROUPS_ALL, both using the column AS_TERRITORY_TYPES_ALL.TERRITORY_GROUP_ID. This associates territory types (categories or classifications) with specific territory groups.

The primary key AS_TERRITORY_GROUPS_PK (TERRITORY_GROUP_ID) supports these relationships, ensuring referential integrity within the territory management schema.