cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper I
Helper I

DAX formulas

Hello, 

I'm new in DAX and I need some help. I try to create new measure to calculate the amount for my accounts. But the problem is that I have amount from each account by months. Like in the table below.

 

And I want to see amount from January in April, from February in May, from March in June, from April in July, from May in August, from June in September and so on.

 

My question is, how can I do it by DAX formulas?

 

 

7 REPLIES 7
Highlighted
Super User III
Super User III

Re: DAX formulas

@olakrupa  Can you provide the sample table (not image) and expected output?

Highlighted
Super User IV
Super User IV

Re: DAX formulas

@olakrupa , Image is not visible

Can you share sample data and sample output.



Did I answer your question? Mark my post as a solution! Appreciate your Kudos!!
Dashboard of My Blogs !! YouTube Channel !! Connect on Linkedin

Proud to be a Super User!

Highlighted
Helper I
Helper I

Re: DAX formulas

@amitchandak Sorry, I did't see my mistake 

Here are base table 

months.png

That should be the outputs

months2.jpg

Highlighted
Super User IV
Super User IV

Re: DAX formulas

@olakrupa , can not tell mistake with image, need sample data



Did I answer your question? Mark my post as a solution! Appreciate your Kudos!!
Dashboard of My Blogs !! YouTube Channel !! Connect on Linkedin

Proud to be a Super User!

Highlighted
Helper I
Helper I

Re: DAX formulas

I thing it's impossible because these are data directly from Dynamics 365 BC. 

Highlighted
Anonymous
Not applicable

Re: DAX formulas

This is very easy on condition that you've got the correct model.

[Balance -3Mth] =
	CALCULATE(
		[Balance],
		DATEADD(
			Calendar[Date],
			-3,
			month
		)
	)


Best

D

Highlighted
Helper I
Helper I

Re: DAX formulas

@Anonymous  I base on three tables and four columns. 

date: Posting_Date (hierarchy: day, month, year) from "General Ledger Entries" table

values: Amount (as a sume) from "General Ledger Entries" table

and accounts from "dictionary VAT' table

 

olakrupa_0-1594118065603.png

I was trying to change your formula for my needs like that 

 

 

 

 

CALCULATE( 'General Ledger Entries'[Amount]; 
		DATEADD(
			'General Ledger Entries'[Posting_Date].[Miesiąc],
			-3,
			month
		)
	)

 

 

but still doesn't working 

Helpful resources

Announcements
Get Ready for Power BI Dev Camp

Get Ready for Power BI Dev Camp

Mark your calendars and join us for our next Power BI Dev Camp!.

Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Tech Marathon

Maratón de Soluciones de Negocio Microsoft

Una semana de contenido con +100 sesiones educativas, consultorios, +10 workshops Premium, Hackaton, EXPO, Networking Hall y mucho más!

Top Solution Authors