Table
RetailGiftCardTable
Gift card table
Holds one record per gift card, keyed by gift card number. It stores the currency, face value, status, validity dates, balance and reload limits. It also shows whether the card is locked and by which channel, store, register and transaction.
- Table name
RetailGiftCardTable- Module
Commerce payments- Table group
Transaction- Table type
Regular- Data per company
Yes- Configuration key
Retail- Primary index
typeEntryIdx- Replacement key
None- Key fields
entryId- Model
Foundation
Fields (23)
| Field and description | Type / EDT / enum | Mandatory | References | In public entities |
|---|---|---|---|---|
entryIdNumber of the gift card. It identifies the record. | String (30)RetailGiftCardId | Yes | RetailGiftCardEntityMCRContinuityCustomerPaymentEntityMCRCustomerCreditPaymentEntityand 3 more | |
ActiveFromDate and time from which the gift card is active. | UtcDateTimeRetailGiftCardActiveFrom | No | RetailGiftCardEntity | |
currencyCodeCurrency of the gift card. | String (3)CurrencyCode | No | Currency.CurrencyCode | RetailGiftCardEntity |
DataAreaIdThe company (legal entity) that the record belongs to. System field. | String (4)DataAreaId | No | None | |
ExpiryDateDate the gift card expires. | DateRetailGiftCardExpireDate | No | RetailGiftCardEntity | |
FaceValueFace value of the gift card. | RealRetailGiftCardFaceValue | No | RetailGiftCardEntity | |
MaxBalanceMSTHighest balance the card may hold (in accounting currency). | RealRetailGiftCardMaxBalanceMST | No | RetailGiftCardEntity | |
MCRGiftCardTypeKind of gift card: email or physical card. | EnumMCRGiftCardType (enum) | No | RetailGiftCardEntity | |
MinReloadMSTSmallest amount allowed when reloading the card (in accounting currency). | RealRetailGiftCardMinReloadMST | No | RetailGiftCardEntity | |
NonReloadableYes or no flag that blocks the card from being reloaded. | EnumRetailGiftCardNonReloadableNoYes (enum) | No | RetailGiftCardEntity | |
OneTimeRedemptionYes or no flag for a card that can be redeemed only once. | EnumRetailGiftCardOneTimeRedemptionNoYes (enum) | No | RetailGiftCardEntity | |
PartitionA system field for the data partition. In most environments every record has the same value. System field. | Int64Partition | 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 | |
replicationCounterCounter value used to track replication of the record. | IntegerRetailReplicationCounter | No | None | |
reservedShows whether the gift card is locked (yes or no). | EnumNoYes (enum) | No | RetailGiftCardEntity | |
reservedByChannelRetail channel that locked the gift card. | Int64RetailChannelRecId | No | RetailChannelTable.RecId | None |
ReservedByStoreIdStore that locked the gift card. | StringRetailStoreId | No | None | |
reservedByTerminalIdRegister that locked the gift card. | StringRetailTerminalId | No | RetailTerminalTable.terminalId | RetailGiftCardEntity |
ReservedByTransactionIdRetail transaction that locked the gift card. | String (44)RetailTransactionId | No | RetailGiftCardEntity | |
StatusStatus of the gift card: active, redeemed or expired, or closed. | EnumRetailGiftCardStatus (enum) | No | RetailGiftCardEntity | |
SysRowVersionA system row version number that is used for change tracking. System field. | Int64SysRowVersion | No | None | |
TableIdA system number that identifies the table. System field. | IntegerTableId | No | None |
Indexes (2)
typeEntryIdxPrimary indexUnique, alternate key.
replicationIdxNot unique.
Relations (3)
Each relation joins RetailGiftCardTable to another table on the fields shown.
Currency→CurrencyJoin on
currencyCode = Currency.CurrencyCodeMany RetailGiftCardTable records → exactly one Currency record
RetailChannelTable→RetailChannelTableJoin on
reservedByChannel = RetailChannelTable.RecIdMany RetailGiftCardTable records → zero or one RetailChannelTable record
RetailTerminalTable→RetailTerminalTableJoin on
reservedByTerminalId = RetailTerminalTable.terminalIdMany RetailGiftCardTable records → exactly one RetailTerminalTable record
Get this data out
Tables are not exposed directly. These public entities read from RetailGiftCardTable; use one of them in Power BI, Power Platform or a data management project.
RetailGiftCardEntity· 14 fields from this tableMCRContinuityCustomerPaymentEntity· 1 field from this tableMCRCustomerCreditPaymentEntity· 1 field from this tableMCRCustomerInvoicePaymentEntity· 1 field from this tableMCRInstallmentPlanCustomerPaymentEntity· 1 field from this tableMCRSalesOrderCustomerPaymentEntity· 1 field from this table
Need help with RetailGiftCardTable in a report, an integration or a migration? Talk to Dr Dynamics.