Personalized Community is here!
Quickly customize your community to find the content you seek.
Choose your path Increase your proficiency with the Dynamics 365 applications that you already use and learn more about the apps that interest you. Up your game with a learning path tailored to today's Dynamics 365 masterminds and designed to prepare you for industry-recognized Microsoft certifications.
Visit Microsoft Learn
2020 Release Wave 2Discover the latest updates and new features to Dynamics 365 planned through March 2021.
Release overview guides and videos Release Plan | Preview 2020 Release Wave 2 TimelineWatch the 2020 Release Wave 1 virtual launch event
The FastTrack program is designed to help you accelerate your Dynamics 365 deployment with confidence.
FastTrack Program | Finance TechTalks | Customer Engagement TechTalks | Upcoming TechTalks
Hello Guys, I have a question.... I need to created a report in AX 2012 R2...
I already know how to create the report and how to do everything in visual studio but each time I do it am only getting data form the first table(datasource) in the query...
These are the tables am using: USTINVOICEJOUR, CUSTTRANS, CUSTSETTLEMENT
This is the query in SQL which works fine....
FROM [CUSTINVOICEJOUR] join [CUSTTRANS] ON CUSTTRANS.INVOICE=CUSTINVOICEJOUR.INVOICEID AND
[CUSTTRANS].AccountNum = [CUSTINVOICEJOUR].InvoiceAccount
and [CUSTTRANS].TransDate = [CUSTINVOICEJOUR].InvoiceDate
and [CUSTTRANS].Voucher = [CUSTINVOICEJOUR].LedgerVoucher
on CUSTSETTLEMENT.TransCompany = [CUSTTRANS].dataAreaId
and CUSTSETTLEMENT.TransRecId = [CUSTTRANS].RecId
and CUSTSETTLEMENT.AccountNum = [CUSTTRANS].AccountNum
WHERE [CUSTSETTLEMENT].DUEDATE = [CUSTINVOICEJOUR].DUEDATE
AND [CUSTSETTLEMENT].DUEDATE between'2018-03-01 01:00:000' AND '2019-03-15 23:00:000'
AND [CUSTSETTLEMENT].TRANSDATE <'2019-02-28 0:0:0'
AND [CUSTINVOICEJOUR].INVOICEID LIKE 'ACP%'
I would like for the where conditions to be dynamic where the user will then go and enter this info and the report prints according. IO know whats i get the query then dropping that in visual studio should not be a problem
Any help would be greatly appreciated if this can be achieved.
You should not use direct SQL in AX because of various reasons you can easily find in the web. For simple report you can use AX query as described here community.dynamics.com/.../developing-ssrs-report-using-query-in-microsoft-dynamics-ax-2012
But personally I prefer to build RDP based reports.
Have you considered using Procedure and editing code to complete logic?
Procedure: It can set some variables for you to enter, specify the time range, and specify the InvoiceID.
create procedure Createreportdynamically(
//Define variables ,for example,
Insert your SQL here
WHERE （Match with your custom variables)
exec Createreportdynamically '2018-03-01 01:00:000','2019-03-15 23:00:000','2019-02-28 0:0:0','ACP','110214M'
Code: Backend development can access the database and call Procedure directly. Of course, parameters are what you are asked to enter when you create a report
You can refer ：https://www.cnblogs.com/armanda/p/6045963.html.
Best Regards ,
Business Applications communities