Table

TrvPolicyViolationsCache

Cache table for policy violations on an expense line

Temporary store of policy violations found on expense or requisition lines. Each record links to the policy rule, the worker and the document. It has no defined key in the metadata.

Table name
TrvPolicyViolationsCache
Module
Expense
Table group
WorksheetLine
Table type
Regular
Data per company
No
Configuration key
Trv
Primary index
RecId
Replacement key
None
Key fields
None
Model
Foundation

Fields (14)

Field and descriptionType / EDT / enumMandatoryReferencesIn public entities
HeaderExpense report or travel requisition the violation belongs to.Int64
RefRecId
NoTrvExpTable.RecIdTrvRequisitionTable.RecIdTrvPolicyViolationsCacheEntity
LineTravel requisition line the violation belongs to.Int64
RefRecId
NoTrvRequisitionLine.RecIdTrvPolicyViolationsCacheEntity
ParentRecIdExpense line the violation belongs to.Int64
RefRecId
NoTrvExpTrans.RecIdTrvPolicyViolationsCacheEntity
PartitionA system field for the data partition. In most environments every record has the same value. System field.Int64
Partition
NoNone
PolicyTypeType of policy that was broken, such as expense or travel cost.Enum
SysPolicyTypeEnum (enum)
NoTrvPolicyViolationsCacheEntity
PolicyViolationLevelSeverity of the violation, which decides what users may do next.Enum
TrvPolicyViolationLevel (enum)
NoTrvPolicyViolationsCacheEntity
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
RulePolicy rule that was broken. It points to a policy rule record.Int64
RefRecId
NoTrvPolicyRule.RecIdTrvPolicyViolationsCacheEntity
SaveDateTimeDate and time the record was saved, in UTC.UtcDateTime
TrvUtcDateTime
NoTrvPolicyViolationsCacheEntity
TableIdA system number that identifies the table. System field.Integer
TableId
NoNone
ViolationDateDate of the violation.Date
TrvDateStd
NoTrvPolicyViolationsCacheEntity
ViolationsCacheIdUnique ID of the cache record.GuidNoTrvPolicyViolationsCacheEntity
WorkerEmployee linked to the violation. It points to a worker record.Int64
TrvHcmWorkerRecId
NoHcmWorker.RecIdTrvPolicyViolationsCacheEntity

Indexes (7)

Relations (6)

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

  • TrvHcmWorker → HcmWorker

    Join on Worker = HcmWorker.RecId

    Many TrvPolicyViolationsCache records → zero or one HcmWorker record

  • TrvExpTable → TrvExpTable

    Join on PolicyType = 2, Header = TrvExpTable.RecId

    Many TrvPolicyViolationsCache records → zero or one TrvExpTable record

  • TrvExpTrans → TrvExpTrans

    Join on ParentRecId = TrvExpTrans.RecId, PolicyType = 2, Line = TrvExpTrans.RecId

    Many TrvPolicyViolationsCache records → zero or one TrvExpTrans record

  • TrvRequisitionLine → TrvRequisitionLine

    Join on PolicyType = 3, Line = TrvRequisitionLine.RecId

    Many TrvPolicyViolationsCache records → zero or one TrvRequisitionLine record

  • TrvRequisitionTable → TrvRequisitionTable

    Join on PolicyType = 3, Header = TrvRequisitionTable.RecId

    Many TrvPolicyViolationsCache records → zero or one TrvRequisitionTable record

  • TrvPolicyRule → TrvPolicyRule

    Join on Rule = TrvPolicyRule.RecId

    Many TrvPolicyViolationsCache records → zero or one TrvPolicyRule record

Get this data out

Tables are not exposed directly. These public entities read from TrvPolicyViolationsCache; use one of them in Power BI, Power Platform or a data management project.

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

Email sales@drdynamics.co.uk