Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Nun
Resolver I
Resolver I

Display a trend of Sales between months period in Power BI

In power BI I use a a file excel as source to get the sales information of the previous month (31.08).

In excel I created a worksheet "Trend", were I collect the previous sales months (31.07,31.06... in excel copy and paste the values of the last column 31.07 in a new column because in the last period there is a formula that call the data of the last period coming from another worksheet "Sales". The creation of the column 31.07 is created before to refresh the data of the another worksheet "Sales" )

Is it possible to have in Power BI a table with the trend?

Practically

the trend table should refresh the information of the column "customers"," customer numbers" from the excel report. I should have the column 31.05-31.06-31.07 coming of the previous reports and in certain way "blocked", not refreshed. The last month from the file excel where there are the sales information of 31.08 refreshing an existing column called "31.08" in "Trend" table.

Hope I was clear.

 

Thanks!

 

3 REPLIES 3
Greg_Deckler
Super User
Super User

@Nun - Sorry, not clear. Not really enough information to go on, please first check if your issue is a common issue listed here: https://community.powerbi.com/t5/Community-Blog/Before-You-Post-Read-This/ba-p/1116882

Also, please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490

The most important parts are:
1. Sample data as text, use the table tool in the editing bar
2. Expected output from sample data
3. Explanation in words of how to get from 1. to 2.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

@Greg_Deckler @amitchandak 

my sincere apologies for not being clear enough.
I have an excel file with a worksheet called "Sales". Here I update the sales data of the previous month every early month. In September the data as at 31 August. An exasmple.
Table1
CustName  Cust. number  Sales  Date
Test                1                            190      31.08.2020
Test1             2                             200     31.08.2020
Test2             3                             300     31.08.2020
 
I would like to create a table with the following information
Cust Name Cust. number are  are columns created ( I created with the measure SELECTCOLUMNS('table1';"CustName";[CustName]..) and updated from table 1 every month
Table2
Columns:CustName -  Cust. number -  31.08.2020  (this column 31.08.2020 is created with the measure: (CALCULATE (FIRSTNONBLANK ( 'Table1'[Sales]; 1 );FILTER(ALL('Table1'); 'Table1'[Date] = (DATE(2020;08;31))))
So Table 2 is
CustName Cust num          31.08.2020     30.09.2020     31.10.2020   .........
Test                1                            190     
Test1             2                            200    
Test2             3                            300   
 Let's think that in October I update the Table1
Custname  Cust nun          Sales     Date
Test                1                            200       30.09.2020   
Test1             2                             500       30.09.2020   
Test2             3                             100       30.09.2020
 
In Table 2 the new column 30.09.2020 with the same measure showed for column 31.08.2020, but different date (2020;09;30)
I get this result
CustName Cust num           31.08.2020  30.09.2020      
  Test                1                                                            200
Test1               2                                                            500
Test2              3                                                             100
Colum 31.08.2020       will be empty because from Table 1 the information for date 31.08.2020 are not anymore available.
Thanks a lot for supporting!
 
 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.