Query/QueryRun with temporary tables (AX/F&O)

I noticed that some developers believe that Query* classes can’t be used to query temporary tables. It is possible; it just requires an extra step that isn’t needed with regular tables. When working with temporary tables, each buffer (variable) of the same table can refer to a different set of temporary data. Therefore using the …

Continue reading ‘Query/QueryRun with temporary tables (AX/F&O)’ »

Compare records in code

When saving a record, I had to check which fields had changed and react in a special way if only certain fields (and not any other) changed their value. I could iterate all fields and compare their values in two table buffers (the original and the updated one), but I thought that D365FO might already …

Continue reading ‘Compare records in code’ »

Thoughts on element prefix vs. suffix

When I read Evaldas Landauskas’s blog post Development guidelines: Prefix Vs. Suffix, I thought I would write a comment below the post and share a few ideas, but then I decided that it’d be better to write my own blog post. Here I have a much better control over formatting and the content will be …

Continue reading ‘Thoughts on element prefix vs. suffix’ »

Splitting .xpo files

I got an .xpo file from an older version of AX with some code of interest and because it had a few thousand lines, it wasn’t exactly easy to navigate. At least splitting it by object would make my life much easier. Fortunately I looked at the internet and found exactly the right tool for …

Continue reading ‘Splitting .xpo files’ »

Reference group and GROUP BY

This blog post explains a problem that you can run into when using reference group controls with grouped data – and a solution for this problem. I have a table which stores references to workers. The field has HcmWorkerRecId data type, i.e. it stores record IDs from HcmWorker table. When I drop this field to …

Continue reading ‘Reference group and GROUP BY’ »