Everybody:
I just make a SSRS report with AX report tools. Sometimes we must get data from AX query. I know how to add a dataset that use AX query, but not all dataset can from standard query, sometimes I must create business logic type dataset because I must process these data.
When I use business logic dataset, I had learned how to get data from SQL query, and know how to return dataTable to dataset. But I don’t know how to get data from user-defined AX query.
I can fetch data from SQL query with below codes:
DataTable table = new System.Data.DataTable(); // new table variable
table = AxQuery.ExecuteQuery("SELECT * FROM InventTable");
but I can’t build success with the codes below:
remark: I had created a ventTableSRS
query in AX AOT.
DataTable ItemQueryTable = FIMCommonHelper.GetParameterDataTable(
FIMAxQueries.InventTableSRS,
new object[] { },
new object[] { });
I found the class of FIMaxQueries
don’t include my query(InventTableSR
S). I try to found where the class of FIMAxQueries
is, but I don’t get a result.
Could someone tell me how to write the codes, so that I can run an AX query and retrieve the result in SSRS report project business logic data method? The best way is to show me a sample codes.
Thanks you very much!
Spark