/LIME/NTREE
transactionMixed keyThe LIME tree structure — one row per node of the location and handling-unit hierarchy stock hangs on, with its object type, its parent node, and the nested-set interval bookkeeping the engine walks the tree with
Structure, not stock — no quantity column exists here; this is the table that resolves a /LIME/NQUAN row's GUID_PARENT into the bin or handling unit it is sitting on
The missing half of the LIME stock model: quantities live on /LIME/NQUAN, attributes on /SCWM/QUAN, and the position on this tree. TYPE and TYPE_PARENT say what kind of object each end of a node link is, which is how a bin node is told apart from a handling-unit node. OVERFLOW is part of the key — a node with many children spills across more than one row, so a naive count of rows is not a count of nodes.
What the badges mean
- master
- Data class: what the table holds — master data, transaction documents, configuration, an organizational object, or a language-striped text companion.
- Semantic key
- Every non-client key column is readable business data —
LGNUMplus a bin, task, or order number. Joins run on the columns you can see (see the quirks guide). - GUID key
- Every non-client key column is a GUID —
RAW(16)on the /SCWM, /SCDL, /LIME, and /SCMB tables, and theCHAR(22)compressed form on the product master. Join the raw column; a hex rendering is for reading only, and the two encodings need converting between (see the quirks guide). - Mixed key
- The key mixes readable and GUID columns in either direction — a product GUID inside an otherwise-readable bin key, or a readable status type inside an otherwise-GUID key. Check which side of a join you are on (see the quirks guide).
- DOCCAT: PDO
- A /SCDL delivery table holds several document categories in one table — inbound and outbound requests, the inbound delivery, the outbound delivery order, and the final outbound delivery — discriminated by
DOCCAT. The chips list the categories this table carries; anchor the one you mean or documents of every kind come back together (see the quirks guide). - Embedded S/4HANA only
- Deployment: shown only when a table does not exist in both embedded S/4HANA EWM and decentralized EWM. No table in this wave is deployment-specific, so the badge stays absent until one is.
Structural facts — how the table is keyed, not a trap by itself
Join & extract hazards — verify before you rely on this
Fields
16 fields · 3 key
16 fields.
| # | Field | Description | Type | Flags |
|---|---|---|---|---|
| 1 | MANDT | Client | CLNT(3) | Key |
| 2 | GUID | GUID of the tree node — the value a quantity row's GUID_PARENT points at | RAW(16) | Key |
| 3 | OVERFLOW | Overflow counter — a node with many children spills across several rows, so node identity is the GUID, not the row | INT4(10) | Key |
| 4 | TYPE | Object type of the node — what kind of object the GUID identifies (a location or a handling unit, for instance) | CHAR(1) | |
| 5 | IDX | Index of the key table the node's object is registered in | CHAR(3) | |
| 6 | GUID_PARENT | GUID of the node above this one — the column a hierarchy walk recurses on | RAW(16) | |
| 7 | TYPE_PARENT | Object type of the parent node | CHAR(1) | |
| 8 | IDX_PARENT | Index of the key table the parent object is registered in | CHAR(3) | |
| 9 | LFT | Left interval bound of the node — nested-set bookkeeping the engine uses to read a subtree in one pass | DEC(31) | |
| 10 | RGT | Right interval bound of the node | DEC(31) | |
| 11 | LVL | Depth of the node in the tree | INT4(10) | |
| 12 | GAP | Interval gap kept free below the node so children can be inserted without renumbering | DEC(31) | |
| 13 | GUID_PN_ADD | GUID of the posting-change or additional document line the node was written by | RAW(16) | |
| 14 | ID_ADD | Line item identifier of that additional document line | NUMC(6) | |
| 15 | TARGET_ADD | Whether the additional record is the source or the target side of the movement | CHAR(1) | |
| 16 | TS_LIME_ADD | LIME internal timestamp of the node in long form (yyyymmddhhmmss with fractional seconds), not the short form the rest of this reference filters on | DEC(21,7) |
Field provenance: hand-curated. 3 key fields.
Boilerplate SQL
Starting point for reading the replicated copy of /LIME/NTREEon Databricks — the client anchor is already in place, the namespaced name is rendered as the underscore bronze name replication targets conventionally land it under, and any RAW16 GUID column selects a hex rendering alongside the raw value. Set your Unity Catalog location, schema, and filter values below; they’re substituted into the SQL and the copy button.
3 parameters not filled: <catalog>, <schema>, <client>
-- ============================================================
-- Table : /LIME/NTREE — The LIME tree structure — one row per node of the location and handling-unit hierarchy stock hangs on, with its object type, its parent node, and the nested-set interval bookkeeping the engine walks the tree with
-- Purpose: Column-selected read of /LIME/NTREE — auto-generated from field metadata
-- Grain : One row per client + GUID + OVERFLOW
-- Caution: Structure, not stock — no quantity column exists here; this is the table that resolves a /LIME/NQUAN row's GUID_PARENT into the bin or handling unit it is sitting on
-- Notes : Auto-generated skeleton for SAP EWM data replicated into your lakehouse — it reads the replicated copy, not the SAP database. Source table /LIME/NTREE; slashes aren't legal in unquoted Databricks identifiers, so replication targets conventionally land it as lime_ntree — adjust to your landing convention (see quirks #namespace-slashes). RAW16 GUID columns are joined raw; the hex aliases are for display only (#guid-keys). Timestamps flagged UTC are DEC(15) yyyymmddhhmmss values in UTC, not warehouse local time (#utc-timestamps).
-- ============================================================
SELECT
t.MANDT AS "Client",
t.GUID AS "GUID of the tree node — the value a quantity row's GUID_PARENT points at",
lower(hex(t.GUID)) AS "GUID of the tree node — the value a quantity row's GUID_PARENT points at (hex)", -- display rendering of the RAW16 GUID — join on the raw column; see quirks guide #guid-keys
t.OVERFLOW AS "Overflow counter — a node with many children spills across several rows, so node identity is the GUID, not the row",
t.TYPE AS "Object type of the node — what kind of object the GUID identifies (a location or a handling unit, for instance)",
t.IDX AS "Index of the key table the node's object is registered in",
t.GUID_PARENT AS "GUID of the node above this one — the column a hierarchy walk recurses on",
lower(hex(t.GUID_PARENT)) AS "GUID of the node above this one — the column a hierarchy walk recurses on (hex)", -- display rendering of the RAW16 GUID — join on the raw column; see quirks guide #guid-keys
t.TYPE_PARENT AS "Object type of the parent node",
t.IDX_PARENT AS "Index of the key table the parent object is registered in",
t.LFT AS "Left interval bound of the node — nested-set bookkeeping the engine uses to read a subtree in one pass",
t.RGT AS "Right interval bound of the node",
t.LVL AS "Depth of the node in the tree",
t.GAP AS "Interval gap kept free below the node so children can be inserted without renumbering",
t.GUID_PN_ADD AS "GUID of the posting-change or additional document line the node was written by",
lower(hex(t.GUID_PN_ADD)) AS "GUID of the posting-change or additional document line the node was written by (hex)", -- display rendering of the RAW16 GUID — join on the raw column; see quirks guide #guid-keys
t.ID_ADD AS "Line item identifier of that additional document line",
t.TARGET_ADD AS "Whether the additional record is the source or the target side of the movement",
t.TS_LIME_ADD AS "LIME internal timestamp of the node in long form (yyyymmddhhmmss with fractional seconds), not the short form the rest of this reference filters on"
FROM <catalog>.<schema>.lime_ntree t
WHERE
t.MANDT = '<client>' -- client filter — drop on single-client systems
ORDER BY t.GUID;Verified August 2026
Landing conventions differ — see namespaced names in a lakehouse.
Relationships
Diagram of 1-hop neighbors — join details below. GUID joins and text-table joins are highlighted; they’re the joins newcomers most often get wrong.
Join details
ON lime_nquan.MANDT = lime_ntree.MANDT AND lime_nquan.GUID_PARENT = lime_ntree.GUID -- RAW16 GUID equality — join raw; hex is for display/conformance only · the join that turns a quantity row into a place — resolve the node before summing anythingthe join that turns a quantity row into a place — resolve the node before summing anything
- /LIME/NTREE/LIME/NTREEGUID join · N:1
ON lime_ntree1.MANDT = lime_ntree2.MANDT AND lime_ntree1.GUID_PARENT = lime_ntree2.GUID -- RAW16 GUID equality — join raw; hex is for display/conformance only · the tree's own parent link — a recursive walk, not a single join; a node's row can repeat across OVERFLOW valuesthe tree's own parent link — a recursive walk, not a single join; a node's row can repeat across OVERFLOW values
Transaction codes that touch this table
Curated: the EWM transactions an analyst would trace back to these rows, and how each one touches them.
R read · W write · R/W read + write
More Stock & Handling Units tables
- /SCWM/AQUAAvailable quants — the stock that warehouse task creation can actually consume, with the bin, handling unit, product, stock type, batch, owner, and entitled party all resolved onto one row
- /SCWM/HUHDRHandling unit header — one row per HU with its external number, packaging material, current storage type and bin, weights, volumes, and the entitled party whose stock it holds
- /SCWM/QUANQuant attributes — the descriptive side of a stock item (units, weight, volume, goods-receipt time, shelf life, country of origin, and the document reference for special stock), keyed by the stock GUID
- /LIME/NQUANThe LIME stock quantities table — the physical quantity of a stock item hanging on one node of the location/handling-unit tree, one row per stock GUID per node per unit of measure