how to obtain the SQL query from X-path retrieve

1
Hi all, We are using a datagrid with a X-path constraint as data source. To evaluate its performance we would like to obtain the exact query Mendix sends to the database. We tried to obtain this query by setting the log levels on the connectionbus_retrieve on trace. Hereby several query's appear in the console. But we were unable to identity the distinct query constructed with the specific X-path constraint. If someone knows a way to link a specific X-path constraint to a specific query that would be of enormous help! Best regards, Romboud
asked
1 answers
0

Setting the loglevel of the connectionbus_retrieve is the right way to go. Note that a form with a datagrid on it triggers multiple retrieves 1 for each filter 1 for each list aggregation result and one for the grid itself. To find the last one find the querie that has a limit equal to the number of the max amount of rows of the grid.

Furthermore there is a setting that automatically logs queries that take over the specified time. If you have reasons to believe your querie is slow on performance it might be worth to enable this setting. I forgot the name of this setting and will get back on that tomorrow.

answered