Table

TaxBenefitCodeSetupData_BR

Benefit code setup data

Holds detail lines for benefit code setup used for Brazil. Each line can be set for a customer, vendor or fiscal establishment, and for an item and a CFOP code. It links to adjustment codes and observation codes.

Table name
TaxBenefitCodeSetupData_BR
Module
Tax
Table group
Miscellaneous
Table type
Regular
Data per company
Yes
Configuration key
None
Primary index
RecId
Replacement key
None
Key fields
None
Model
Foundation

Fields (17)

Field and descriptionType / EDT / enumMandatoryReferencesIn public entities
AccountCodeShows if the account relation is a single account, a group or all.Enum
TableGroupAll (enum)
NoNone
AccountRelationThe customer, group or fiscal establishment group that the line applies to.String (20)
InventCustVendRel
NoCustGroup.CustGroupCustTable.AccountNumFiscalEstablishmentGroup_BR.FiscalEstablishmentGroupIdFiscalEstablishment_BR.FiscalEstablishmentIdVendGroup.VendGroupVendTable.AccountNumNone
CFOPCodeShows if the CFOP relation is a single CFOP, a group or all.Enum
TableGroupAll (enum)
NoNone
CFOPRelationThe CFOP code or CFOP group that the line applies to.String
CFOPRelation
NoCFOPGroup_BR.CFOPGroupCFOPTable_BR.CFOPIdNone
CustVendTypeType of party: customer, vendor or fiscal establishment.Enum
CustVendType_BR (enum)
NoNone
DataAreaIdThe company (legal entity) that the record belongs to. System field.String (4)
DataAreaId
NoNone
FBFiscalDocumentAdjustmentCodeICMS_53Adjustment code 5.3, pointing to a fiscal document adjustment code record.Int64
FBFiscalDocumentAdjustmentCodeICMS_53
NoFBFiscalDocumentAdjustmentCodeICMS_BR.RecIdNone
FBFiscalDocumentAdjustmentCodeICMS_BRThe fiscal document adjustment code (ICMS) linked to the line.Int64
RefRecId
NoFBFiscalDocumentAdjustmentCodeICMS_BR.RecIdNone
FBObservationCodeTable_BRThe observation code linked to the line.Int64
FBObservationCodeRecId_BR
NoFBObservationCodeTable_BR.RecIdNone
ItemCodeShows if the item relation is a single item, a group or all.Enum
TableGroupAll (enum)
NoNone
ItemRelationThe item or item group that the line applies to.String (20)
InventItemRelation
NoInventItemGroup.ItemGroupIdInventTable.ItemIdNone
PartitionA system field for the data partition. In most environments every record has the same value. System field.Int64
Partition
NoNone
RecIdA unique number that the system gives to every record. Other tables often use it to point to this record. System field.Int64
RecId
NoNone
RecVersionA system number that changes each time the record is updated. It is used to detect conflicting updates. System field.Integer
RecVersion
NoNone
SysRowVersionA system row version number that is used for change tracking. System field.Int64
SysRowVersion
NoNone
TableIdA system number that identifies the table. System field.Integer
TableId
NoNone
TaxBenefitCodeSetupHeading_BRThe benefit code setup (FCP setup) heading this line belongs to.Int64
RefRecId
NoTaxBenefitCodeSetupHeading_BR.RecIdNone

Indexes (1)

Relations (14)

Each relation joins TaxBenefitCodeSetupData_BR to another table on the fields shown.

  • CustGroup → CustGroup

    Join on CustVendType = null, AccountCode = 1, AccountRelation = CustGroup.CustGroup

    Many TaxBenefitCodeSetupData_BR records → zero or one CustGroup record

  • CustTable → CustTable

    Join on CustVendType = null, AccountCode = null, AccountRelation = CustTable.AccountNum

    Many TaxBenefitCodeSetupData_BR records → zero or one CustTable record

  • FiscalEstablishmentGroup → FiscalEstablishmentGroup_BR

    Join on CustVendType = 2, AccountCode = 1, AccountRelation = FiscalEstablishmentGroup_BR.FiscalEstablishmentGroupId

    Many TaxBenefitCodeSetupData_BR records → zero or one FiscalEstablishmentGroup_BR record

  • FiscalEstablishmentTable → FiscalEstablishment_BR

    Join on CustVendType = 2, AccountCode = null, AccountRelation = FiscalEstablishment_BR.FiscalEstablishmentId

    Many TaxBenefitCodeSetupData_BR records → zero or one FiscalEstablishment_BR record

  • InventItemGroup → InventItemGroup

    Join on ItemCode = 1, ItemRelation = InventItemGroup.ItemGroupId

    Many TaxBenefitCodeSetupData_BR records → zero or one InventItemGroup record

  • InventTable → InventTable

    Join on ItemCode = null, ItemRelation = InventTable.ItemId

    Many TaxBenefitCodeSetupData_BR records → zero or one InventTable record

  • TaxBenefitCodeSetupHeading_BR → TaxBenefitCodeSetupHeading_BR

    Join on TaxBenefitCodeSetupHeading_BR = TaxBenefitCodeSetupHeading_BR.RecId

    Many TaxBenefitCodeSetupData_BR records → exactly one TaxBenefitCodeSetupHeading_BR record

  • VendGroup → VendGroup

    Join on CustVendType = 1, AccountCode = 1, AccountRelation = VendGroup.VendGroup

    Many TaxBenefitCodeSetupData_BR records → zero or one VendGroup record

  • VendTable → VendTable

    Join on CustVendType = 1, AccountCode = null, AccountRelation = VendTable.AccountNum

    Many TaxBenefitCodeSetupData_BR records → zero or one VendTable record

  • FBFiscalDocumentAdjustmentCodeICMS_BR → FBFiscalDocumentAdjustmentCodeICMS_BR

    Join on FBFiscalDocumentAdjustmentCodeICMS_BR = FBFiscalDocumentAdjustmentCodeICMS_BR.RecId, FBFiscalDocumentAdjustmentCodeICMS_BR.Table52 = NoYes::Yes

    Zero or one TaxBenefitCodeSetupData_BR record → exactly one FBFiscalDocumentAdjustmentCodeICMS_BR record

  • CFOPTable → CFOPTable_BR

    Join on CFOPCode = null, CFOPRelation = CFOPTable_BR.CFOPId

    Many TaxBenefitCodeSetupData_BR records → zero or one CFOPTable_BR record

  • CFOPGroup → CFOPGroup_BR

    Join on CFOPCode = 1, CFOPRelation = CFOPGroup_BR.CFOPGroup

    Many TaxBenefitCodeSetupData_BR records → zero or one CFOPGroup_BR record

  • FBFiscalDocumentAdjustmentCodeICMS_53 → FBFiscalDocumentAdjustmentCodeICMS_BR

    Join on FBFiscalDocumentAdjustmentCodeICMS_53 = FBFiscalDocumentAdjustmentCodeICMS_BR.RecId, FBFiscalDocumentAdjustmentCodeICMS_BR.Table52 = null

    Many TaxBenefitCodeSetupData_BR records → zero or one FBFiscalDocumentAdjustmentCodeICMS_BR record

  • FBObservationCodeTable_BR → FBObservationCodeTable_BR

    Join on FBObservationCodeTable_BR = FBObservationCodeTable_BR.RecId

    Zero or one TaxBenefitCodeSetupData_BR record → zero or one FBObservationCodeTable_BR record

Get this data out

No public entity reads from TaxBenefitCodeSetupData_BR. Its data is only reachable through the application, a custom entity or a database export.

Need help with TaxBenefitCodeSetupData_BR in a report, an integration or a migration? Talk to Dr Dynamics.

Email sales@drdynamics.co.uk