P_SchedgAgrmtItemHistory2

DDL: P_SCHEDGAGRMTITEMHISTORY2 SQL: PSCHAGITMHIST2 Type: view CONSUMPTION

Scheduling Agreement Item History 2

P_SchedgAgrmtItemHistory2 is a Consumption CDS View that provides data about "Scheduling Agreement Item History 2" in SAP S/4HANA. It reads from 4 data sources (P_SchedulingAgreementHistory, P_SchedgAgrmtItemSLQty, I_Schedgagrmthdr, I_SchedgAgrmtItm) and exposes 32 fields with key fields SchedulingAgreement, SchedulingAgreementItem.

Data Sources (4)

SourceAliasJoin Type
P_SchedulingAgreementHistory History left_outer
P_SchedgAgrmtItemSLQty ScheduleLine inner
I_Schedgagrmthdr SchedulingAgreement inner
I_SchedgAgrmtItm SchedulingAgreementItem from

Parameters (1)

NameTypeDefault
P_DisplayCurrency displaycurrency

Annotations (8)

NameValueLevelField
AbapCatalog.sqlViewName PSCHAGITMHIST2 view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
ClientHandling.algorithm #SESSION_VARIABLE view
VDM.private true view
VDM.viewType #CONSUMPTION view
AccessControl.authorizationCheck #CHECK view
EndUserText.label Scheduling Agreement Item History 2 view

Fields (32)

KeyFieldSource TableSource FieldDescription
KEY SchedulingAgreement I_SchedgAgrmtItm SchedulingAgreement Scheduling Agreement
KEY SchedulingAgreementItem I_SchedgAgrmtItm SchedulingAgreementItem Schedule Item Number
Supplier I_Schedgagrmthdr Supplier Supplier
PurchasingOrganization I_Schedgagrmthdr PurchasingOrganization Purchasing Organization
PurchasingGroup I_Schedgagrmthdr PurchasingGroup Purchasing Group
CompanyCode I_Schedgagrmthdr CompanyCode Receiver Company Code
DocumentCurrency I_SchedgAgrmtItm DocumentCurrency Document Currency
ValidityStartDate I_Schedgagrmthdr ValidityStartDate Validity Start Date
ValidityEndDate I_Schedgagrmthdr ValidityEndDate ValidTo
PurchasingDocumentType I_Schedgagrmthdr PurchasingDocumentType RFQ Type
PurchasingDocumentCategory I_Schedgagrmthdr PurchasingDocumentCategory Doc. Category
ReleaseIsNotCompleted ReleaseIsNotCompleted Subj.to Release
PurchasingProcessingStatus PurchasingProcessingStatus Proc. State
Plant I_SchedgAgrmtItm Plant Valuation Area
StorageLocation I_SchedgAgrmtItm StorageLocation StorageLocation
MaterialGroup I_SchedgAgrmtItm MaterialGroup Product Group
Material I_SchedgAgrmtItm Material Vehicle Model
OrderQuantityUnit I_SchedgAgrmtItm OrderQuantityUnit Sales Unit
PurchasingDocumentOrderDate I_Schedgagrmthdr PurchasingDocumentOrderDate PO Date
PostingDate PostingDate Posting Date for GR
OrderPriceUnitToOrderUnitNmrtr I_SchedgAgrmtItm OrderPriceUnitToOrderUnitNmrtr Quantity Conversion Numerator
OrdPriceUnitToOrderUnitDnmntr I_SchedgAgrmtItm OrdPriceUnitToOrderUnitDnmntr Quantity Conversion Denominator
ProductType I_SchedgAgrmtItm ProductType Product Type Group
MaterialType I_SchedgAgrmtItm MaterialType Material Type
AccountAssignmentCategory I_SchedgAgrmtItm AccountAssignmentCategory Acct Assgmt Cat
MultipleAcctAssgmtDistribution I_SchedgAgrmtItm MultipleAcctAssgmtDistribution Distribution
PartialInvoiceDistribution I_SchedgAgrmtItm PartialInvoiceDistribution Partial invoice
GoodsReceiptQuantity GoodsReceiptQuantity Delivered
InvoiceReceiptQty InvoiceReceiptQty
TargetQuantity I_SchedgAgrmtItm TargetQuantity Target Quantity
NetPriceQuantity I_SchedgAgrmtItm NetPriceQuantity Price Unit
ScheduleLineOrderQuantity ScheduleLineOrderQuantity Scheduled Qty

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_SchedgAgrmtItemHistory2.
-- 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.
-- SQL view name: PSCHAGITMHIST2
-- Parameters: P_DisplayCurrency : displaycurrency

CREATE VIEW P_SchedgAgrmtItemHistory2 AS
SELECT
  SchedulingAgreementItem.SchedulingAgreement AS SchedulingAgreement,
  SchedulingAgreementItem.SchedulingAgreementItem AS SchedulingAgreementItem,
  SchedulingAgreement.Supplier AS Supplier,
  SchedulingAgreement.PurchasingOrganization AS PurchasingOrganization,
  SchedulingAgreement.PurchasingGroup AS PurchasingGroup,
  SchedulingAgreement.CompanyCode AS CompanyCode,
  SchedulingAgreementItem.DocumentCurrency AS DocumentCurrency,
  SchedulingAgreement.ValidityStartDate AS ValidityStartDate,
  SchedulingAgreement.ValidityEndDate AS ValidityEndDate,
  SchedulingAgreement.PurchasingDocumentType AS PurchasingDocumentType,
  SchedulingAgreement.PurchasingDocumentCategory AS PurchasingDocumentCategory,
  ReleaseIsNotCompleted,
  PurchasingProcessingStatus,
  SchedulingAgreementItem.Plant AS Plant,
  SchedulingAgreementItem.StorageLocation AS StorageLocation,
  SchedulingAgreementItem.MaterialGroup AS MaterialGroup,
  SchedulingAgreementItem.Material AS Material,
  SchedulingAgreementItem.OrderQuantityUnit AS OrderQuantityUnit,
  SchedulingAgreement.PurchasingDocumentOrderDate AS PurchasingDocumentOrderDate,
  PostingDate,
  SchedulingAgreementItem.OrderPriceUnitToOrderUnitNmrtr AS OrderPriceUnitToOrderUnitNmrtr,
  SchedulingAgreementItem.OrdPriceUnitToOrderUnitDnmntr AS OrdPriceUnitToOrderUnitDnmntr,
  SchedulingAgreementItem.ProductType AS ProductType,
  SchedulingAgreementItem.MaterialType AS MaterialType,
  SchedulingAgreementItem.AccountAssignmentCategory AS AccountAssignmentCategory,
  SchedulingAgreementItem.MultipleAcctAssgmtDistribution AS MultipleAcctAssgmtDistribution,
  SchedulingAgreementItem.PartialInvoiceDistribution AS PartialInvoiceDistribution,
  GoodsReceiptQuantity,
  InvoiceReceiptQty,
  SchedulingAgreementItem.TargetQuantity AS TargetQuantity,
  SchedulingAgreementItem.NetPriceQuantity AS NetPriceQuantity,
  ScheduleLineOrderQuantity
FROM I_SchedgAgrmtItm AS SchedulingAgreementItem
INNER JOIN I_Schedgagrmthdr AS SchedulingAgreement ON /* join condition not captured in parsed metadata */
INNER JOIN P_SchedgAgrmtItemSLQty AS ScheduleLine ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN P_SchedulingAgreementHistory AS History ON /* join condition not captured in parsed metadata */
;