Data entity
FiscalEstablishmentEntity
Holds fiscal establishments, used for Brazil. It includes tax registrations such as CNPJ and IE, and NF-e and NFC-e settings like authority, certificate, environment and version. It joins party, accountant and organization data. The key is the fiscal establishment ID.
- Entity name
FiscalEstablishmentEntity- Public entity name
FiscalEstablishment- OData collection
FiscalEstablishments- Category
Not set- Module
Accounts receivable- Read-only
No- Data management enabled
Yes- Configuration key
None- Keys
FiscalEstablishmentId- Staging table
FiscalEstablishmentStaging
Use it in Power BI and Power Platform
- OData URL
https://<environment>/data/FiscalEstablishments- Dataverse virtual table
mserp_fiscalestablishmententity. Listed in the virtual-table catalogue. An administrator must make the virtual table visible before you can use it.- Data management
- Enabled: you can use it in import and export projects.
Data sources
FiscalEstablishment_BR· rootAccountant_BR· OuterJoin toFiscalEstablishment_BR· read-onlyDirPartyLocation· InnerJoin toFiscalEstablishment_BR· read-onlyDirPartyTable· InnerJoin toDirPartyLocation· read-onlyDirPerson· Derived toDirPartyTableDirOrganizationBase· Derived toDirPartyTableDirOrganization· Derived toDirOrganizationBaseOMInternalOrganization· Derived toDirOrganizationBaseCompanyInfo· Derived toOMInternalOrganizationOMTeam· Derived toOMInternalOrganizationOMOperatingUnit· Derived toOMInternalOrganizationLogisticsLocation· InnerJoin toDirPartyLocation· read-onlyFiscalEstablishmentGroup_BR· InnerJoin toFiscalEstablishment_BR· read-onlyFiscalEstablishmentSalesIssuer(tableFiscalEstablishment_BR) · OuterJoin toFiscalEstablishment_BR· read-only
Fields (45)
| Field and description | Type / EDT / enum | Mandatory | OData / Dataverse | References | Lineage root |
|---|---|---|---|---|---|
AccountantPoints to the accountant record linked to this establishment. | Int64AccountantRecId_BR | No | No (private) | Accountant_BR.RecId | FiscalEstablishment_BR.Accountant_BR |
CCMMunicipal taxpayer registration number (CCM) of the establishment. | String (20)CCMNum_BR | No | Yes | FiscalEstablishment_BR.CCMNum_BR | |
CNPJCNPJ number, the Brazilian company tax ID, of the establishment. | String (20)CNPJCPFNum_BR | No | Yes | FiscalEstablishment_BR.CNPJCPFNum_BR | |
AddressPoints to the party location record that gives the establishment's address. | Int64DirPartyLocationRecId | Yes | No (private) | DirPartyLocation.RecId | FiscalEstablishment_BR.DirPartyLocation |
NFeAuthorityCode of the NF-e authority that the establishment sends electronic documents to. | StringEFDocAuthorityId_BR | No | Yes | EFDocAuthority_BR.AuthorityId | FiscalEstablishment_BR.EFDocAuthority |
PrintDanfeWhenAprovedYes or no choice for printing the DANFE automatically once an NF-e is approved. | EnumEFDocAutomaticPrinting_BR
| No | Yes | FiscalEstablishment_BR.EFDocAutomaticPrinting | |
BlockPostingNotValidatedNfeXmlYes or no choice: only allow posting of NF-e documents that have a valid access key. | Enum
| No | Yes | FiscalEstablishment_BR.EFDocBlockPostingNotValidatedXml | |
NFeDigitalCertificateSubject text of the digital certificate used to sign electronic fiscal documents. | String (960)DigitalCertificateSubject | No | Yes | FiscalEstablishment_BR.EFDocDigitalCertificateSubject | |
EmailTemplateApprovedNFeE-mail template ID used when an NF-e is approved. | StringSysEmailId | No | Yes | SysEmailTable.EmailId | FiscalEstablishment_BR.EFDocEmailApproved |
EmailTemplateCanceledNFeE-mail template ID used when an NF-e is cancelled. | StringSysEmailId | No | Yes | SysEmailTable.EmailId | FiscalEstablishment_BR.EFDocEmailCanceled |
EmailTemplateCorrectionLetterNFeE-mail template ID used for the correction letter event. | StringSysEmailId | No | Yes | SysEmailTable.EmailId | FiscalEstablishment_BR.EFDocEmailEvent |
NFeEnvironmentEnvironment for NF-e: testing, production or blank. | Enum
| No | Yes | FiscalEstablishment_BR.EFDocEnvironment | |
PreprintedSecurityFormYes or no choice showing whether a pre-printed security form is used. | Enum
| No | Yes | FiscalEstablishment_BR.EFDocPrePrintedSecurityForm | |
SendDanfePdfInEmailYes or no choice for attaching the DANFE as a PDF to the e-mail. | Enum
| No | Yes | FiscalEstablishment_BR.EFDocSendPdfInEmail | |
ValidateXmlSchemaChoice to check the XML schema of the NF-e when the document is posted. | EnumEFDocValidateSchemaOnPosting_BR
| No | Yes | FiscalEstablishment_BR.EFDocValidateSchemaOnPosting | |
NFeVersionVersion of the NF-e feature in use: 2.0, 3.1 or 4.0. | Enum
| No | Yes | FiscalEstablishment_BR.EFDocVersion | |
FciToIntrastateEnabledYes or no choice for applying FCI to operations inside the same state. | Enum
| No | Yes | FiscalEstablishment_BR.FciToIntrastateEnabled | |
FiscalEstablishmentGroupPoints to the fiscal establishment group this establishment is in. | Int64FiscalEstablishmentGroupRecId_BR | Yes | No (private) | FiscalEstablishmentGroup_BR.RecId | FiscalEstablishment_BR.FiscalEstablishmentGroup_BR |
FiscalEstablishmentIdUnique ID of the fiscal establishment. It is the business key of the table. | StringFiscalEstablishmentId_BR | Yes | Yes | FiscalEstablishment_BR.FiscalEstablishmentId | |
SalesIssuerPoints to another fiscal establishment that issues sales documents for this one. | Int64RefRecId | No | No (private) | FiscalEstablishment_BR.RecId | FiscalEstablishment_BR.FiscalEstablishmentSalesIssuer |
FiscalOrganizationPoints to the fiscal organization that this establishment belongs to. | Int64FiscalOrganizationRecId_BR | No | No (private) | FiscalOrganization_BR.RecId | FiscalEstablishment_BR.FiscalOrganization_BR |
IEState registration number (IE) of the establishment. | String (20)IENum_BR | No | Yes | FiscalEstablishment_BR.IENum_BR | |
ClosedWarehouseYes or no flag marking the establishment as a closed warehouse. | EnumNoYesId
| No | Yes | FiscalEstablishment_BR.IsClosedWarehouse | |
NameName of the fiscal establishment. | String (60)FiscalEstablishmentName_BR | No | Yes | FiscalEstablishment_BR.Name | |
NextFiscalPrinterDailyReportNumberNext number to use for the daily operation report of the fiscal printer (ECF). | IntegerPositiveNumber | No | Yes | FiscalEstablishment_BR.NextFiscalPrinterDailyReportNumber | |
NIRENIRE number, the company registration number at the trade board. | String (11)NIRE_BR | No | Yes | FiscalEstablishment_BR.NIRE | |
SPEDContribReportingTypeReporting type for NF-e and ECF in SPED contributions: detailed or consolidated. | Enum
| No | Yes | FiscalEstablishment_BR.SPEDContribReportingType | |
MatchNfeXmlOnPostingYes or no choice to stop NF-e posting when the XML does not match. | Enum
| No | Yes | FiscalEstablishment_BR.EFDocMatchNfeXmlOnPosting | |
NFCeAuthorityCode of the authority that receives consumer electronic documents (NFC-e). | StringEFDocAuthorityId_BR | No | Yes | EFDocAuthority_BR.AuthorityId | FiscalEstablishment_BR.ConsumerEFDocAuthority |
CSCCSC code, a security code used for NFC-e, stored as long text. | String (-1)ConsumerEFDocCsc | No | Yes | FiscalEstablishment_BR.ConsumerEFDocCsc | |
CSCTokenShort token that goes with the CSC code for NFC-e. | String (6)ConsumerEFDocCscToken | No | Yes | FiscalEstablishment_BR.ConsumerEFDocCscToken | |
NFCeEmailApprovedE-mail template ID used when an NFC-e is approved. | StringSysEmailId | No | Yes | SysEmailTable.EmailId | FiscalEstablishment_BR.ConsumerEFDocEmailApproved |
NFCeEnvironmentEnvironment for NFC-e: testing, production or blank. | Enum
| No | Yes | FiscalEstablishment_BR.ConsumerEFDocEnvironment | |
NFCeSendPdfInEmailYes or no choice for attaching the DANFE NFC-e as a PDF to the e-mail. | Enum
| No | Yes | FiscalEstablishment_BR.ConsumerEFDocSendPdfInEmail | |
NFCeVersionVersion of the NFC-e feature in use: 2.0, 3.1 or 4.0. | Enum
| No | Yes | FiscalEstablishment_BR.ConsumerEFDocVersion | |
AccountantCPFCPF number, the Brazilian personal tax ID. | String (20)CPFNum_BR | Yes | Yes | Accountant_BR.CPFNum_BR | |
AccountantCRCCRC registration number of the accountant. | String (20)CRCNum_BR | Yes | Yes | Accountant_BR.CRCNum_BR | |
AddressLocationPoints to the location. Part of the key. | Int64LogisticsLocationRecId | Yes | No (private) | LogisticsLocation.RecId | DirPartyLocation.Location |
AddressPartyPoints to the party in the global address book. Part of the key. | Int64DirPartyRecId | Yes | No (private) | DirPartyTable.RecId | DirPartyLocation.Party |
PartyNumberUnique ID of the party. It is the key of the table. | String (40)DirPartyNumber | Yes | Yes | DirPartyTable.PartyNumber | |
AddressNameUnique ID of the location. It is the key of the table. | String (40)LogisticsLocationId | Yes | Yes | LogisticsLocation.LocationId | |
FiscalEstablishmentGroupIdUnique ID of the fiscal establishment group. | StringFiscalEstablishmentGroupId_BR | Yes | Yes | FiscalEstablishmentGroup_BR.FiscalEstablishmentGroupId | |
FiscalEstablishmentSalesIssuerIdUnique ID of the fiscal establishment. It is the business key of the table. | StringFiscalEstablishmentId_BR | No | Yes | FiscalEstablishment_BR.FiscalEstablishmentId | |
EFDocNFe402018005v110Yes or no switch for turning on the latest NF-e technical note. | Enum
| No | Yes | FiscalEstablishment_BR.EFDocNFe402018005v110 | |
EFDocNFeTechNotesSelected NF-e technical note, by year, number and version. | Enum
| No | Yes | FiscalEstablishment_BR.EFDocNFeTechNotes |
Foreign keys (13)
Each field below points to the key of another table. Join on it in Power BI, or follow the link to an entity that exposes that table.
Accountant→Accountant_BR.RecId(key of Accountant_BR)Zero or one FiscalEstablishment_BR record → zero or one Accountant_BR record
Accountant_BR details: see AccountantEntity
Address→DirPartyLocation.RecId(key of DirPartyLocation)Exactly one FiscalEstablishment_BR record → exactly one DirPartyLocation record
DirPartyLocation details: see DirPartyLocationPostalAddressV2Entity, HcmWorkerPostalAddressDualWriteEntity, CustCustomerV3Entity
EmailTemplateApprovedNFe→SysEmailTable.EmailId(key of SysEmailTable)Many FiscalEstablishment_BR records → zero or one SysEmailTable record
Not exposed by a public entity.
EmailTemplateCanceledNFe→SysEmailTable.EmailId(key of SysEmailTable)Many FiscalEstablishment_BR records → zero or one SysEmailTable record
Not exposed by a public entity.
EmailTemplateCorrectionLetterNFe→SysEmailTable.EmailId(key of SysEmailTable)Many FiscalEstablishment_BR records → zero or one SysEmailTable record
Not exposed by a public entity.
FiscalEstablishmentGroup→FiscalEstablishmentGroup_BR.RecId(key of FiscalEstablishmentGroup_BR)Exactly one FiscalEstablishment_BR record → exactly one FiscalEstablishmentGroup_BR record
FiscalEstablishmentGroup_BR details: see FiscalEstablishmentGroupEntity, TaxesMatrixEntity
SalesIssuer→FiscalEstablishment_BR.RecId(key of FiscalEstablishment_BR)Exactly one FiscalEstablishment_BR record → exactly one FiscalEstablishment_BR record
FiscalEstablishment_BR details: see EFDocTechResponsibleInformationEntity, FiscalOrganizationFiscalEstablishmentEntity, AssetFixedAssetEntity
FiscalOrganization→FiscalOrganization_BR.RecId(key of FiscalOrganization_BR)Many FiscalEstablishment_BR records → zero or one FiscalOrganization_BR record
FiscalOrganization_BR details: see FiscalOrganizationEntity, FiscalOrganizationFiscalAuditorEntity, FiscalOrganizationFiscalEstablishmentEntity
NFCeEmailApproved→SysEmailTable.EmailId(key of SysEmailTable)Many FiscalEstablishment_BR records → zero or one SysEmailTable record
Not exposed by a public entity.
AddressLocation→LogisticsLocation.RecId(key of LogisticsLocation)Many DirPartyLocation records → exactly one LogisticsLocation record
LogisticsLocation details: see AccountantEntity, CustPostalAddressV2Entity, DirPartyLocationPostalAddressEntity
AddressParty→DirPartyTable.RecId(key of DirPartyTable)Many DirPartyLocation records → exactly one DirPartyTable record
DirPartyTable details: see CustFoundationEntity, smmContactPersonV2Entity, CustCustomerV3Entity
Need help with FiscalEstablishmentEntity in Power BI, Power Automate or a migration? Talk to Dr Dynamics.