Skip to content
JDE Reference

R12855

Batch UBE

User Defined Depreciation — the batch job that computes period depreciation for assets under user-defined depreciation rules and writes the resulting balances and journals.

Lineage hook

Rows written by R12855 carry …PID = 'R12855' in their audit columns — a ready-made marker for isolating the records this program produced. See the audit-columns guide →

Boilerplate SQL

Databricks SQL

Starting point for querying the tables behind this program. Set your Unity Catalog location and filter values below — they’re substituted into the SQL and the copy button.

Query parameters
-- ============================================================
-- Program: R12855 User Defined Depreciation — the batch job that computes period depreciation for assets under user-defined depreciation rules and writes the resulting balances and journals.
-- Purpose: User Defined Depreciation — the batch job that computes period depreciation for assets under user-defined depreciation rules and writes the resulting balances and journals. — auto-generated boilerplate from program-table-map
-- Grain  : F1202 × F1201, F0911 — 1:N joins yield one row per detail line
-- Tables : F1202, F1201, F0911
-- Notes  : Auto-generated skeleton. Julian dates are converted to DATE and implied-decimal amounts are scaled (verify decimals in F9210). Audit columns (…USER/…PID/…UPMJ) are omitted — see the quirks guide. Set catalog/schema to your Unity Catalog location; fill remaining placeholders (<...>) for your tenant.
-- ============================================================
SELECT
  h.FLAID AS "Short account ID of the cost, accumulated depreciation, or expense account",
  h.FLCTRY AS "Century of the fiscal year",
  h.FLFY AS "Fiscal year of the balance row",
  h.FLFQ AS "Fiscal quarter — obsolete but still part of the primary key, normally blank",
  h.FLLT AS "Ledger type (AA actual, plus tax and alternate depreciation ledgers like D1-D9)",
  h.FLSBL AS "Subledger value, part of the key; usually blank for asset balances",
  h.FLNUMB AS "Asset item number — joins to F1201",
  h.FLSBLT AS "Subledger type qualifying the subledger value",
  f0.GLDCT AS "Document type of the journal entry (JE, PV, RI, etc.).",
  f0.GLDOC AS "Document number of the journal entry.",
  f0.GLKCO AS "Company that assigned the document number (key company).",
  CASE WHEN f0.GLDGJ IS NULL OR f0.GLDGJ = 0 THEN NULL ELSE DATE_ADD(MAKE_DATE(1900 + CAST(f0.GLDGJ AS INT) DIV 1000, 1, 1), CAST(f0.GLDGJ AS INT) % 1000 - 1) END AS "G/L date driving the fiscal period the line posts to.",  -- CYYDDD Julian → DATE
  f0.GLJELN AS "Line number within the journal entry.",
  f0.GLEXTL AS "Line extension code completing the unique key."
FROM <catalog>.<schema_data>.f1202 h
LEFT JOIN <catalog>.<schema_data>.f1201 f
  ON f.FANUMB = h.FLNUMB
LEFT JOIN <catalog>.<schema_data>.f0911 f0
  ON f0.GLLT = h.FLLT
ORDER BY h.FLAID;

2 parameters not filled: <catalog>, <schema_data>

Tables Used by This Program

How these tables connect. Nodes are clickable.

Join details

  • F1202F1201foreign key · N:1
    ON f1202.FLNUMB = f1201.FANUMB