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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Anonymous
Not applicable

Ignore a filter

HI,

I am working on stock report wherein I need to show different volume of stocks on two diffrent dates in one chart. For this purpose,

I fetched below mentioned columns from DB.

 

  • I fetched "Quantiy" column twice and named those columns as "Quantity1" and "Quantity2"
  • I fetched "Date" column twice and named those columns as "Date1" and "Date2"

I also created two measures with following formula:

  • QuantityMeasure1 = CALCULATE(sum(Query1[Quantity1]),ALL(Query1[Date2]))
  • QuantityMeasure2 = CALCULATE(sum(Query1[Quantity2]),ALL(Query1[Date1]))

Now I want the value of QuantityMeasure1 should only be dependent on Date1 and on the other hand, QuantityMeasure2 should only be dependent on Date2. But after any change in date slicer (Date1 and Date2), I get same value in both measures.

 

Note: I am using Direct mode to develope this report.

 

Please help .

 

Thanks in advance for all efforts.

3 REPLIES 3
BI-lingual
Frequent Visitor

Hi, can you please uplaod a sample data for more clarity?

As I understood from the description, you're using 2 quantity measure in single chart, split by same date axis, right?

Now, even if you have 2 separate date filters, but you still have a common x-axis date! Did I miss something here?

Anonymous
Not applicable

Thanks @Greg_Deckler for sharing thoughts on this. Here is a screenshot of sample data in database.

 

Sample Data.jpg

To simplify this eqaution,  I fetched below mentioned columns from DB.

 

  • I fetched "Order Quantiy" column twice and named those columns as "Quantity1" and "Quantity2"
  • I fetched "Order Date" column twice and named those columns as "Date1" and "Date2"

I also created two measures with following formula:

  • QuantityMeasure1 = CALCULATE(sum(Query1[Quantity1]),ALL(Query1[Date2]))
  • QuantityMeasure2 = CALCULATE(sum(Query1[Quantity2]),ALL(Query1[Date1]))

Thanks for looking into this.

Greg_Deckler
Community Champion
Community Champion

Replace your ALL function with ALLEXCEPT if you want Measure1 to be tied only to Date1, then use Date1 in that measure instead of Date2 and vice versa.



Follow on LinkedIn
@ 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!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Users online (7,908)