Table
RetailTransactionDiscountTransHistory
Archived commerce discount transactions
Archived discount lines for Commerce transactions. Each row records the discount type and origin (customer, periodic, manual, loyalty or tender), amounts, percentages and offer details. Rows link to a sales line within a transaction by store, register and transaction number.
- Table name
RetailTransactionDiscountTransHistory- Module
Commerce transactions and orders- Table group
Transaction- Table type
Regular- Data per company
Yes- Configuration key
Retail- Primary index
None- Replacement key
None- Key fields
None- Model
Foundation
Fields (30)
| Field and description | Type / EDT / enum | Mandatory | References | In public entities |
|---|---|---|---|---|
AmountFull discount amount; currency not stated in the metadata. | RealRetailDiscAmount | No | None | |
AppliedDiscountLineNumLine number of the applied discount. | RealLineNum | No | None | |
BundleIdID of the discount bundle. | IntegerRetailDiscountBundleId | No | None | |
CalculatedPricingPriorityNumberPricing priority number of the discount. | IntegerRetailPricingPriorityNumber | No | None | |
ChannelReference to the channel record, stored as a record ID. | Int64RefRecId | No | None | |
CustomerDiscountTypeKind of customer discount: none, line, multiline or total discount. | EnumRetailCustomerDiscountType (enum) | No | None | |
DataAreaIdThe company (legal entity) that the record belongs to. System field. | String (4)DataAreaId | No | None | |
DealPriceDeal price value for the discount. | RealRetailDealPriceValue | No | None | |
DiscountAmountCash discount amount; currency not stated in the metadata. | RealDiscAmount | No | None | |
DiscountCodeCode of the discount. | String (60)RetailDiscountCodeId | No | None | |
DiscountCostCost of the discount to the business. | RealRetailDiscountCost | No | None | |
DiscountLineRecIdRecord ID of the related discount line. | Int64RefRecId | No | None | |
DiscountOriginTypeWhere the discount came from: customer, periodic, manual, loyalty points or tender discount. | EnumRetailDiscountOriginType (enum) | No | None | |
EffectivePercentageEffective discount percentage. | RealDiscPct | No | None | |
LineNumLine number of the discount line. | RealLineNum | Yes | None | |
ManualDiscountTypeKind of manual discount: line or total, as an amount or a percentage. | EnumRetailManualDiscountType (enum) | No | None | |
OriginLocation number showing where the record came from. | String (50)RetailConnDistributionLocationId | No | None | |
PartitionA system field for the data partition. In most environments every record has the same value. System field. | Int64Partition | No | None | |
PercentageDiscount percentage. | RealDiscPct | No | None | |
PeriodicDiscountOfferIdID of the periodic discount offer. | String (20)RetailOfferIdEx3 | No | None | |
RecIdA unique number that the system gives to every record. Other tables often use it to point to this record. System field. | Int64RecId | No | None | |
RecVersionA system number that changes each time the record is updated. It is used to detect conflicting updates. System field. | IntegerRecVersion | No | None | |
ReplicationCounterFromOriginCounter value from the origin location, used to track replication of the record. | IntegerRetailReplicationCounter | No | None | |
SaleLineNumLine number of the sales line the discount applies to. | RealRetailTransactionSalesLineNum | No | None | |
StoreIdNumber of the store where the transaction took place. | StringRetailStoreId | No | None | |
SysRowVersionA system row version number that is used for change tracking. System field. | Int64SysRowVersion | No | None | |
SysRowVersionNumberSystem version number of the row. It has no label.low confidence | Int64SysRowVersionNumber | No | None | |
TableIdA system number that identifies the table. System field. | IntegerTableId | No | None | |
TerminalIdNumber of the register where the transaction took place. | StringRetailTerminalId | No | None | |
TransactionIdNumber of the transaction. | String (44)RetailTransactionId | Yes | None |
Indexes (2)
TransactionDiscountTransUIdxStoreId,TerminalId,TransactionId,SaleLineNum,Channel,LineNum,DataAreaId,PartitionUnique, alternate key.
transactionIdxStoreId,TerminalId,TransactionId,Channel,DataAreaId,PartitionNot unique.
Get this data out
No public entity reads from RetailTransactionDiscountTransHistory. Its data is only reachable through the application, a custom entity or a database export.
Need help with RetailTransactionDiscountTransHistory in a report, an integration or a migration? Talk to Dr Dynamics.