Finds stock with cover above a threshold or a long idle time, gives each position to its planner with the options, and posts the decision in the ERP.
Delta tables in Unity Catalog are read in place through a SQL warehouse: the app sends only the filter and the columns it needs. The Backbone landing model (bronze, silver and gold) is the usual source, so history and aggregates are already prepared and lineage is registered in Unity Catalog.
| Object | Read from | Fields the app uses | Freshness |
|---|---|---|---|
| Stock position | silver.stock_position · gold.stock_daily | on_hand_qty (on hand) · stock_value (value) · last_movement_date (last movement) · material_id (material) | prepared by the Backbone; refreshed on its schedule |
| Material master | silver.material | material_id (id) · description (desc) · material_type (type) · plant (plant) | prepared by the Backbone; refreshed on its schedule |
| Forecast | silver.forecast · gold.forecast_versions | forecast_qty (qty) · material_id (material) · plant (plant) · period (period) | prepared by the Backbone; refreshed on its schedule |
| Sales order line | silver.sales_order_line | ordered_qty (qty) · so_number (number) · so_line (line) · customer_id (customer) | prepared by the Backbone; refreshed on its schedule |
| Batch | silver.batch | batch_id (batch) · material_id (material) · expiry_date (expiry) · production_date (produced) | prepared by the Backbone; refreshed on its schedule |
| Journal line | silver.journal_line · gold.journal_lines | document_id (document) · gl_account (account) · amount_lc (amount) · cost_center (cost center) | prepared by the Backbone; refreshed on its schedule |
In plain words: A stock position worth more than 5,000 whose on-hand quantity covers more than 12 months of forecast and open orders, or whose last movement is older than 180 days.
The criterion runs in Databricks through the data handler, so only the matching rows return. The editor shows the rows it selects, and their count, as it is written.
# start criterion in Databricks fields stock_value > 5000 and (on_hand_qty > 12 months of forecast_qty + ordered_qty or last_movement_date < today - 180) # the same criterion in canonical fields {stock.value} > 5000 and ({stock.on_hand} > 12 months of {forecast.qty} + {so.qty} or {stock.last_movement} < today - 180)
Decisions are recorded in a Lima-owned gold table with MERGE INTO, so notebooks and dashboards see them next to the history. The operational write goes to the system of record through its released interface, and the app records the acknowledgement. For this app the operational change (transfer to another plant or scrap posted as a goods movement) goes to SAP S/4HANA or Oracle Fusion through its released interface, and the pair pages for those systems show the exact call.
| Object | What changes | Interface |
|---|---|---|
| Stock position | transfer to another plant or scrap posted as a goods movement; quantity moved to blocked stock while a decision is open | MERGE INTO gold.lima_app_decisions |
| Material master | plant status set to phase-out so planning stops creating new orders | MERGE INTO gold.lima_app_decisions · operational write to the ERP |
| Journal line | the agreed reserve change posted as a journal at month end | MERGE INTO gold.lima_app_decisions |
Each write stores the identifier Databricks returns beside the decision, the person and the time, so the log answers who changed what, and the reconciliation shows it arrived.
Unity Catalog grants and row filters are mapped to Lima access policies once, so a person sees the same rows in the app that they see in a notebook.
This app reads stock position from Databricks because the screens need history at scale: months of rows, aggregates by period, several versions. The Backbone lands the objects in the conformed model and refreshes them on a schedule, and the handler reads them in place with the filter and the columns pushed down. The person's grants in Databricks decide what they see.
The operational rows the person acts on can come live from the ERP in the same app: one handler per object per system, and a screen that shows both.
The screens read through handlers that leave the rows in Databricks. The conformed tables it reads were landed there by the Backbone from the ERP; the app reads them there.
The prerequisites above: an integration identity with read rights on the objects listed and write rights on the interfaces named, connectivity, and the scopes agreed with the process owner.
Yes. The screens, criteria and roles stay; the handlers are re-bound to the other system's objects, and the app's other system pages show them.
Bring the process and the systems it touches. In the first session we register the data handlers, draw the levels or the lanes and run the first screen on your live rows.