Drop Down MenusCSS Drop Down MenuPure CSS Dropdown Menu

Monday, 18 June 2018

How to find relationship between Purchase order table and Cost Center in Dynamics AX? – Solved


Hi developers, I am writing this blog for helping one of my internet friend who asked for my help.

Query - How to get Financial Dimension Cost Center value for the Report in Dynamics AX? He needs financial dimension cost center value for Purchase order report. 



Solution Query:

select distinct CC.NAME,D1.DIMENSIONATTRIBUTEVALUESET
from dbo.PURCHTABLE P
join dbo.PURCHLINE PL on P.PURCHID = PL.PURCHID
left join DIMENSIONATTRIBUTEVALUESETITEM D1 on D1.DIMENSIONATTRIBUTEVALUESET = PL.DEFAULTDIMENSION
left join DIMENSIONATTRIBUTEVALUE D2 on D2.RECID = D1.DIMENSIONATTRIBUTEVALUE
left join DIMENSIONATTRIBUTE D3 on D3.RECID = D2.DIMENSIONATTRIBUTE        
left join DimAttributeOMCostCenter CC on CC.VALUE = D1.DISPLAYVALUE
where D3.NAME = 'CostCenter'


Hope you find the article helpful and interesting. For any query, comment us below.

 

Click imagination hunt to read latest blogs.


Keep learning and sharing...

No comments:

Post a comment

Featured post

Think that makes you rich and richer

 Napolean said: “You can think and grow rich, but if you can be brought up like most people with work and you won't starve, this wil...