How to Troubleshoot Issues in XDS policy

How to Debug/Troubleshoot Issues

If while using XDS you come across an instance where a user has more or less rows from a constrained table than you think they should you will have to try and debug the XDS policy. There are two ways of doing that:

  • Execute a snippet of X++ code to see the SQL statement generated for a particular XDS policy (an example of this can be found in the white paper resource link below)
  • Run a SELECT statement against the ModelSecPolRuntimeEx table to see the human readable query stored for this XDS policy
    • For example, if we look for the CustomerGroupPolicy from the example above in the table the ModeledQueryDebugInfo column shows the SQL query.

Another issue that you may see is a performance impact once XDS policies have been applied. In this case you will need to review the simplicity of your queries, the indexes on your tables, the proper joins are being used, and take into account the number of rows within each table you are using.

Using XDS within D365FO will have an impact on the performance of queries on a table, the goal is to minimize this impact. There a couple things to keep in mind:

  • Follow standard best practices of developing SQL queries (using indexes on join conditions, correct primary keys, etc)
  • Simplify queries as much as possible, don’t have unnecessary joins

Leave a comment

Design a site like this with WordPress.com
Get started