P_CKHS

DDL: P_CKHS Type: view_entity BASIC

P_CKHS is a Basic CDS View in SAP S/4HANA. It reads from 1 data source (ckhs) and exposes 83 fields with key fields lednr, CostingReferenceObject, ProdCostEstNumber, CostingType, CostingDate. It has 1 association to related views.

Data Sources (1)

SourceAliasJoin Type
ckhs ckhs from

Associations (1)

CardinalityTargetAliasCondition
[0..1] I_UnitOfMeasure _UnitOfMeasure $projection.ValuationQuantityUnit = _UnitOfMeasure.UnitOfMeasure

Annotations (4)

NameValueLevelField
AccessControl.authorizationCheck #NOT_REQUIRED view
AccessControl.personalData.blocking #NOT_REQUIRED view
VDM.viewType #BASIC view
VDM.private true view

Fields (83)

KeyFieldSource TableSource FieldDescription
KEY lednr lednr Ledger
KEY CostingReferenceObject bzobj Reference Obj.
KEY ProdCostEstNumber kalnr ProdCostEst.No.
KEY CostingType kalka Costing Type
KEY CostingDate kadky Costing Date
KEY CostingVersion tvers Costing Version
KEY ValuationVariant bwvar Valuation Variant
KEY CostIsEnteredManually kkzma Additive Costs
CompanyCode bukrs Value
ControllingArea kokrs Org. Value
fcpmg fcpmg Distribution Key
froper froper From Period
diper diper Period Interval
toper toper To Period Key
kkart kkart Costing Variant
gjahr gjahr Settlement Year
erfdt erfdt Entry Date
erfnm erfnm Created By
aendt aendt Date
aennm aennm Changed By
absdt absdt Closed on
absnm absnm Closed by
krsdt krsdt Exch. Rate Date
statk statk Status
strng strng Control
psdat psdat Pricing Date
CostingLotSize menge WarrCountValue
ValuationQuantityUnit meeht Valuation Unit
TotalAmountInCoCodeCrcy hwges Total Value(LC)
hwgfx hwgfx TVal Fixed (LC)
TotalAmountInGroupCrcy fwges Total Value(FC)
CompanyCodeCurrency hwaer Local Currency
GroupCurrency fwaer Transaction Curr.
ukurs ukurs Rate
kurst kurst Fix.rate type (EMU)
ffact ffact Ratio (from)
tfact tfact Ratio (to)
gwrt1 gwrt1 Total value 1
gwrt2 gwrt2 Total value 1
gwrt3 gwrt3 Total value 1
gwrt4 gwrt4 Total value 1
gwrt5 gwrt5 Total value 1
stflg stflg Reversal Ind.
ztflg ztflg Time-Based
fvflg fvflg Fixed/Variable
dlflg dlflg Deletion Flag
frflg frflg Released
prvfn prvfn Pricing Proc.
pkanz pkanz No. Price Comps
psanz psanz Number of Items
knnz1 knnz1 Cost Est. Excel
knnz2 knnz2 Postprocessing
knnz3 knnz3 Unit Costg Ind.
knnz4 knnz4 Unit Costg Ind.
knnz5 knnz5 Unit Costg Ind.
me_summ1 me_summ1 Unit of Measure
summ1_kpf summ1_kpf QtyTotalItmCatS
summ2_kpf summ2_kpf CapSpendTotCatS
summ3_kpf summ3_kpf Items total
extnr extnr External number
kostl kostl Substitute CC
aufnr aufnr SettlementOrder
kstar kstar Settlement CE
hrkft hrkft Origin group order
kalsm kalsm Search Proced.
zschl zschl Overhead key
template template TRUE
objnr objnr Val. Obj. No.
twges twges Total Value
tkurst tkurst Exch. Rate Type
twaer twaer Trans. Currency
kkbwvar kkbwvar Valtn Variant
kksaprl kksaprl Release
tkurs tkurs Item Exch. Rate
kzroh kzroh Material Comp.
filepath filepath Description
filename filename URL or Filenam Path
ckcm ckcm Costng Model
ckcmv ckcmv Number
maxcid maxcid Max. Comp. ID.
inthier inthier With Int. Hier.
log_handle log_handle Migration Log Handle
_UnitOfMeasure _UnitOfMeasure

Derived SQL interpretation, reconstructed from the parsed view metadata (data sources, associations, and field mappings). SAP annotations are omitted and the structure is reformulated as SQL — this is a functional approximation, not the verbatim SAP source.

-- Derived SQL interpretation of CDS view P_CKHS.
-- Reconstructed from parsed metadata (data sources, associations, fields).
-- SAP annotations are omitted and the structure is reformulated as SQL;
-- this is a functional approximation, not the verbatim SAP source. Some join
-- conditions may be unavailable and a few CDS constructs are kept as-is.

CREATE VIEW P_CKHS AS
SELECT
  lednr,
  bzobj AS CostingReferenceObject,
  kalnr AS ProdCostEstNumber,
  kalka AS CostingType,
  kadky AS CostingDate,
  tvers AS CostingVersion,
  bwvar AS ValuationVariant,
  kkzma AS CostIsEnteredManually,
  bukrs AS CompanyCode,
  kokrs AS ControllingArea,
  fcpmg,
  froper,
  diper,
  toper,
  kkart,
  gjahr,
  erfdt,
  erfnm,
  aendt,
  aennm,
  absdt,
  absnm,
  krsdt,
  statk,
  strng,
  psdat,
  menge AS CostingLotSize,
  meeht AS ValuationQuantityUnit,
  hwges AS TotalAmountInCoCodeCrcy,
  hwgfx,
  fwges AS TotalAmountInGroupCrcy,
  hwaer AS CompanyCodeCurrency,
  fwaer AS GroupCurrency,
  ukurs,
  kurst,
  ffact,
  tfact,
  gwrt1,
  gwrt2,
  gwrt3,
  gwrt4,
  gwrt5,
  stflg,
  ztflg,
  fvflg,
  dlflg,
  frflg,
  prvfn,
  pkanz,
  psanz,
  knnz1,
  knnz2,
  knnz3,
  knnz4,
  knnz5,
  me_summ1,
  summ1_kpf,
  summ2_kpf,
  summ3_kpf,
  extnr,
  kostl,
  aufnr,
  kstar,
  hrkft,
  kalsm,
  zschl,
  template,
  objnr,
  twges,
  tkurst,
  twaer,
  kkbwvar,
  kksaprl,
  tkurs,
  kzroh,
  filepath,
  filename,
  ckcm,
  ckcmv,
  maxcid,
  inthier,
  log_handle
FROM ckhs
LEFT OUTER JOIN I_UnitOfMeasure AS _UnitOfMeasure ON ValuationQuantityUnit = _UnitOfMeasure.UnitOfMeasure  -- association [0..1]
;