Product documentation
In This Topic
    Cost and sales price calculation data clean up
    In This Topic

    In , cost and sales price information is stored in the DYSAPCCostSalesPriceReference table. This table can hold up to six records per source record (e.g., a sales order line).

    The link to the original source record is maintained in the DYSAPCCostSalesPriceLink table.

    Price Calculation Breakdown Tables

    Details on how prices are calculated from purchase to sales are stored in the following related tables:

    Table Name Description
    DYSAPCCostSalesPrice
    Reference
    Cost and sales price reference data
    DYSAPCCostSalesPrice
    Link
    Link between cost, sales price, and transactions
    DYSAPCCostSales
    SimulationHeader
    Simulation header for cost to sales calculations
    DYSAPCCostSales
    SimulationLine
    Line-level cost to sales simulations
    DYSAPCCostSales
    SimulationLine
    Breakdown
    Detailed breakdown of simulation lines

    Managing Historical Data

    Over time, these tables may accumulate a significant number of records, some of which may become obsolete. To help manage this data, you can use the "Clean up Cost to sales price calculation information" job found under: Module Price and margin management - HSO > Periodic > Clean up

    This job allows you to specify:

    Source Table Lookup

    The Source Table lookup shows all tables currently linked to the DYSAPCCostSalesPriceLink table. This includes tables like AgreementLines (Sales and Purchase Agreements) that are not yet implemented in %%DYSPRI%.

    If an extension is made to the DYSAPCCostSalesPriceLink table (e.g., adding a new table relation), the extended table will automatically appear in the Source Table lookup list.

     

    Date Evaluation Logic

    The system evaluates both CreatedDateTime and ModifiedDateTime to determine a record's age. If both are available, both must be older than the specified threshold. All records older than this date will be be deleted.

    For source tables without either field, an alternative date field is used:

    Source Table Field Used for Age Evaluation
    SalesLine ModifiedDateTime
    CustQuotationTrans QuotationDate
    CustQuotationConfirmTrans QuotationDate
    CustConfirmTrans ConfirmDate
    CustPackingSlipTrans CreatedDateTime
    CustInvoiceTrans ModifiedDateTime
    SalesQuotationLine ModifiedDateTime
    RetailPeriodicDiscount ValidTo
    PurchLine ModifiedDateTime
    PriceDiscAdminTrans ToDate
    PriceDisc ToDate
    PurchRFQ CreatedDateTime