Data entity
TrvPolicyViolationsCacheEntity
Holds cached policy violations found on expense lines. Each record is identified by a violations cache ID. It links to the worker, the policy rule and the policy, and shows the violation level, the rule name and the date.
- Entity name
TrvPolicyViolationsCacheEntity- Public entity name
PolicyViolationsCache- OData collection
PolicyViolationsCache- Category
Not set- Module
Travel and expense- Read-only
No- Data management enabled
Yes- Configuration key
Trv- Keys
ViolationsCacheId- Staging table
TrvPolicyViolationsCacheStaging
Use it in Power BI and Power Platform
- OData URL
https://<environment>/data/PolicyViolationsCache- Dataverse virtual table
mserp_trvpolicyviolationscacheentity. 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
TrvPolicyViolationsCache· rootTrvHcmWorker(tableHcmWorker) · OuterJoin toTrvPolicyViolationsCache· read-onlyTrvPolicyRule· OuterJoin toTrvPolicyViolationsCache· read-onlySysPolicy· InnerJoin toTrvPolicyRule· read-onlySysPolicyRuleType· InnerJoin toTrvPolicyRule· read-onlySysPolicyRuleType_SysPolicySourceDocumentRuleType(tableSysPolicySourceDocumentRuleType) · Derived toSysPolicyRuleType
Fields (22)
| Field and description | Type / EDT / enum | Mandatory | OData / Dataverse | References | Lineage root |
|---|---|---|---|---|---|
ViolationsCacheIdUnique ID of the cache record. | Guid | No | Yes | TrvPolicyViolationsCache.ViolationsCacheId | |
HeaderExpense report or travel requisition the violation belongs to. | Int64RefRecId | No | No (private) | TrvExpTable.RecIdTrvRequisitionTable.RecId | TrvPolicyViolationsCache.Header |
HeaderIdIdentifies the header record that the violation belongs to. | String (20) | No | Yes | computed | |
HeaderLegalEntityCompany that owns the header record. | String (20)CompanyId | No | Yes | computed | |
LineTravel requisition line the violation belongs to. | Int64RefRecId | No | No (private) | TrvRequisitionLine.RecId | TrvPolicyViolationsCache.Line |
LineIdIdentifies the expense line where the violation was found. | String (20) | No | Yes | computed | |
ParentRecIdExpense line the violation belongs to. | Int64RefRecId | No | No (private) | TrvExpTrans.RecId | TrvPolicyViolationsCache.ParentRecId |
ParentIdIdentifies the parent record of the line.low confidence | String (30) | No | Yes | computed | |
PolicyTypeType of policy that was broken, such as expense or travel cost. | Enum
| No | Yes | TrvPolicyViolationsCache.PolicyType | |
PolicyViolationLevelSeverity of the violation, which decides what users may do next. | Enum
| No | Yes | TrvPolicyViolationsCache.PolicyViolationLevel | |
RulePolicy rule that was broken. It points to a policy rule record. | Int64RefRecId | No | No (private) | TrvPolicyRule.RecId | TrvPolicyViolationsCache.Rule |
PolicyPoints to the policy this rule belongs to. | Int64RefRecId | Yes | No (private) | SysPolicy.RecId | SysPolicyRule.Policy |
PolicyNameName of the policy. | String (100)SysPolicyName | Yes | Yes | SysPolicy.Name | |
PolicyPolicyTypePoints to the policy type of this policy. | Int64RefRecId | Yes | No (private) | SysPolicyType.RecId | SysPolicy.PolicyType |
PolicyRuleTypePoints to the type of rule. | Int64RefRecId | Yes | No (private) | SysPolicyRuleType.RecId | SysPolicyRule.PolicyRuleType |
PolicyRuleTypeNameName of the rule type. | String (100)SysPolicyName | Yes | Yes | SysPolicyRuleType.Name | |
PolicyRuleTypePolicyTypePoints to the policy type this rule type belongs to. | Int64RefRecId | Yes | No (private) | SysPolicyType.RecId | SysPolicyRuleType.PolicyType |
PolicyRuleValidFromDate and time from which the rule is valid. | UtcDateTimeValidFromDateTime | No | Yes | SysPolicyRule.ValidFrom | |
SaveDateTimeDate and time the record was saved, in UTC. | UtcDateTimeTrvUtcDateTime | No | Yes | TrvPolicyViolationsCache.SaveDateTime | |
ViolationDateDate of the violation. | DateTrvDateStd | No | Yes | TrvPolicyViolationsCache.ViolationDate | |
WorkerEmployee linked to the violation. It points to a worker record. | Int64TrvHcmWorkerRecId | No | No (private) | HcmWorker.RecId | TrvPolicyViolationsCache.Worker |
PersonnelNumberNumber that identifies the worker within the organisation. | String (25)HcmPersonnelNumberId | No | Yes | HcmWorker.PersonnelNumber |
Foreign keys (10)
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.
Header→TrvExpTable.RecId(key of TrvExpTable)Relation also requires PolicyType = 2.
Many TrvPolicyViolationsCache records → zero or one TrvExpTable record
TrvExpTable details: see TrvExpMobileReportApprovalEntity, TrvCopilotAutomationReportEntity, TrvExpMobileReportEntity
Header→TrvRequisitionTable.RecId(key of TrvRequisitionTable)Relation also requires PolicyType = 3.
Many TrvPolicyViolationsCache records → zero or one TrvRequisitionTable record
TrvRequisitionTable details: see TrvRequisitionTableEntity, TrvRequisitionTableBiEntity
Line→TrvRequisitionLine.RecId(key of TrvRequisitionLine)Relation also requires PolicyType = 3.
Many TrvPolicyViolationsCache records → zero or one TrvRequisitionLine record
TrvRequisitionLine details: see TrvRequisitionLineBiEntity
ParentRecId→TrvExpTrans.RecId(key of TrvExpTrans)Join on all of:
ParentRecId=TrvExpTrans.RecId,Line=TrvExpTrans.RecIdRelation also requires PolicyType = 2.
Many TrvPolicyViolationsCache records → zero or one TrvExpTrans record
TrvExpTrans details: see TrvCopilotAutomationExpenseEntity, TrvExpMobileExpenseEntity, TrvExpMobileExpenseLineAttachedToReportEntity
Rule→TrvPolicyRule.RecId(key of TrvPolicyRule)Many TrvPolicyViolationsCache records → zero or one TrvPolicyRule record
TrvPolicyRule details: see TrvPolicyRuleEntity, TrvPolicyLanguageTxtEntity, TrvPolicyViolationsLogEntity
Policy→SysPolicy.RecId(key of SysPolicy)Many SysPolicyRule records → exactly one SysPolicy record
SysPolicy details: see HcmBenefitEligibilityPolicyEntity, SysPolicyOrganizationEntity, TrvPolicyLanguageTxtEntity
PolicyPolicyType→SysPolicyType.RecId(key of SysPolicyType)Many SysPolicy records → exactly one SysPolicyType record
SysPolicyType details: see SysPolicyTypeEntity, HcmBenefitEligibilityRuleEntity, TrvPolicyLanguageTxtEntity
PolicyRuleType→SysPolicyRuleType.RecId(key of SysPolicyRuleType)Many SysPolicyRule records → exactly one SysPolicyRuleType record
SysPolicyRuleType details: see SysPolicyRuleTypeEntity, HcmBenefitEligibilityPolicyRuleTypeEntity, PayrollPremiumEarningPolicyRuleTypeEntity
PolicyRuleTypePolicyType→SysPolicyType.RecId(key of SysPolicyType)Many SysPolicyRuleType records → exactly one SysPolicyType record
SysPolicyType details: see SysPolicyTypeEntity, HcmBenefitEligibilityRuleEntity, TrvPolicyLanguageTxtEntity
Worker→HcmWorker.RecId(key of HcmWorker)Many TrvPolicyViolationsCache records → zero or one HcmWorker record
HcmWorker details: see TrvExpMobileUserDisplayInfoEntity, BusinessProcessHeaderEntity, HcmInjuryIncidentEntity
Need help with TrvPolicyViolationsCacheEntity in Power BI, Power Automate or a migration? Talk to Dr Dynamics.