How to display unique data in dialog field in Axapta

Hi All,

I have a table which has duplicate data for a specific field.

I am using that field in report for dialog field, in dialog look up it should not show the duplicate values

Please help.

Ambanna Yatnal

Hi Ambana, Unfortunately there is no “DISTINCT” keyword in AX, Try using “group by” in your query or if you are using QueryBuildDataSource, use addSortField method along with orderMode propety.

Hope that helps.


Hi Kartik,

Thanks for the reply.

I know that we can achieve this by Group By option in form or report but in dialog how do we do this. How can I set dialog field value as unique. If you have any sample code to achieve this task, please can provide it.

Thank you


Ambanna Yatnal

Which field you have added to the dialog?

Hi Kranthi,

I have added a EDT to dialog, which has relation to a table and its filed shipmentid. This table is used for importing some data on regular bases (like dumping data into this table). As we do not maintain unique record. Hence I need to provide distinct data in dialog.


Ambanna Yatnal