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 · root
  • TrvHcmWorker (table HcmWorker) · OuterJoin to TrvPolicyViolationsCache · read-only
  • TrvPolicyRule · OuterJoin to TrvPolicyViolationsCache · read-only
  • SysPolicy · InnerJoin to TrvPolicyRule · read-only
  • SysPolicyRuleType · InnerJoin to TrvPolicyRule · read-only
  • SysPolicyRuleType_SysPolicySourceDocumentRuleType (table SysPolicySourceDocumentRuleType) · Derived to SysPolicyRuleType

Fields (22)

Field and descriptionType / EDT / enumMandatoryOData / DataverseReferencesLineage root
ViolationsCacheIdUnique ID of the cache record.GuidNoYesTrvPolicyViolationsCache.ViolationsCacheId
HeaderExpense report or travel requisition the violation belongs to.Int64
RefRecId
NoNo (private)TrvExpTable.RecIdTrvRequisitionTable.RecIdTrvPolicyViolationsCache.Header
HeaderIdIdentifies the header record that the violation belongs to.String (20)NoYescomputed
HeaderLegalEntityCompany that owns the header record.String (20)
CompanyId
NoYescomputed
LineTravel requisition line the violation belongs to.Int64
RefRecId
NoNo (private)TrvRequisitionLine.RecIdTrvPolicyViolationsCache.Line
LineIdIdentifies the expense line where the violation was found.String (20)NoYescomputed
ParentRecIdExpense line the violation belongs to.Int64
RefRecId
NoNo (private)TrvExpTrans.RecIdTrvPolicyViolationsCache.ParentRecId
ParentIdIdentifies the parent record of the line.low confidenceString (30)NoYescomputed
PolicyTypeType of policy that was broken, such as expense or travel cost.Enum
SysPolicyTypeEnum
  • PurchasingPolicy 7
  • ApprovalPolicy 1
  • TrvExpensePolicy 2
  • TrvRequisitionPolicy 3
  • AuditPolicy 5
  • VendInvoicesPolicy 6
  • None 0
  • HcmBenefitEligibilityPolicy 8
  • PayrollPremiumEarningGenerationPolicy 9
  • ExpExpensePolicy 11
  • TimesheetPolicy 10
NoYesTrvPolicyViolationsCache.PolicyType
PolicyViolationLevelSeverity of the violation, which decides what users may do next.Enum
TrvPolicyViolationLevel
  • None 0
  • Warning 2
  • Error 3
  • ApproveJustification 4
  • SubmitJustification 5
  • SubmitApproveJustification 6
NoYesTrvPolicyViolationsCache.PolicyViolationLevel
RulePolicy rule that was broken. It points to a policy rule record.Int64
RefRecId
NoNo (private)TrvPolicyRule.RecIdTrvPolicyViolationsCache.Rule
PolicyPoints to the policy this rule belongs to.Int64
RefRecId
YesNo (private)SysPolicy.RecIdSysPolicyRule.Policy
PolicyNameName of the policy.String (100)
SysPolicyName
YesYesSysPolicy.Name
PolicyPolicyTypePoints to the policy type of this policy.Int64
RefRecId
YesNo (private)SysPolicyType.RecIdSysPolicy.PolicyType
PolicyRuleTypePoints to the type of rule.Int64
RefRecId
YesNo (private)SysPolicyRuleType.RecIdSysPolicyRule.PolicyRuleType
PolicyRuleTypeNameName of the rule type.String (100)
SysPolicyName
YesYesSysPolicyRuleType.Name
PolicyRuleTypePolicyTypePoints to the policy type this rule type belongs to.Int64
RefRecId
YesNo (private)SysPolicyType.RecIdSysPolicyRuleType.PolicyType
PolicyRuleValidFromDate and time from which the rule is valid.UtcDateTime
ValidFromDateTime
NoYesSysPolicyRule.ValidFrom
SaveDateTimeDate and time the record was saved, in UTC.UtcDateTime
TrvUtcDateTime
NoYesTrvPolicyViolationsCache.SaveDateTime
ViolationDateDate of the violation.Date
TrvDateStd
NoYesTrvPolicyViolationsCache.ViolationDate
WorkerEmployee linked to the violation. It points to a worker record.Int64
TrvHcmWorkerRecId
NoNo (private)HcmWorker.RecIdTrvPolicyViolationsCache.Worker
PersonnelNumberNumber that identifies the worker within the organisation.String (25)
HcmPersonnelNumberId
NoYesHcmWorker.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.

Need help with TrvPolicyViolationsCacheEntity in Power BI, Power Automate or a migration? Talk to Dr Dynamics.

Email sales@drdynamics.co.uk