Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
 
					
				
		
Good Afternoon,
I have tried to build a report which takes two tables from our system, apppends them on top of one another in order to create one table and then use this as my dataset.
Within this table, I have applied a number of filters as I only want to bring in certain data.
I have a DAX function which is calculating the number of order available in the current month. It looks like this:
Solved! Go to Solution.
Hi @Anonymous 
Please try
Orders Available in Month DAX =
SUMX (
    VALUES ( 'JDE F0101'[Address Number] ),
    CALCULATE (
        VAR ordersAvlbyCust =
            IF (
                SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Forward Orders] )
                    > SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Orders Available in Month] ),
                0,
                SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Orders Available in Month] )
                    + SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Credit Notes] )
                    - SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Forward Orders] )
            )
        RETURN
            DIVIDE ( ordersAvlbyCust, 100000 )
    )
)@Anonymous 
Please try
Orders Available in Month DAX =
SUMX (
    SUMMARIZE (
        'JDE F0101',
        'JDE F0101'[Address Number],
        'JDE F0101'[Address Name]
    ),
    CALCULATE (
        VAR ordersAvlbyCust =
            IF (
                SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Forward Orders] )
                    > SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Orders Available in Month] ),
                0,
                SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Orders Available in Month] )
                    + SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Credit Notes] )
                    - SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Forward Orders] )
            )
        RETURN
            DIVIDE ( ordersAvlbyCust, 100000 )
    )
) 
					
				
		
Perfect - thank you so much!!
Hi @Anonymous 
Please try
Orders Available in Month DAX =
SUMX (
    VALUES ( 'JDE F0101'[Address Number] ),
    CALCULATE (
        VAR ordersAvlbyCust =
            IF (
                SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Forward Orders] )
                    > SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Orders Available in Month] ),
                0,
                SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Orders Available in Month] )
                    + SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Credit Notes] )
                    - SUMX ( 'JDE Tables Appended', 'JDE Tables Appended'[Forward Orders] )
            )
        RETURN
            DIVIDE ( ordersAvlbyCust, 100000 )
    )
)If I add a variance column into the model, I have the same issue??
@Anonymous 
Please help me out with a screenshot so I can better understand
I have a new measure which references "Orders Available in Month DAX" which you have helped me with yesterday (thank you :-D) as per below:
 
					
				
				
			
		
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
 
            | User | Count | 
|---|---|
| 9 | |
| 5 | |
| 4 | |
| 3 | |
| 3 | 
| User | Count | 
|---|---|
| 23 | |
| 12 | |
| 11 | |
| 10 | |
| 9 |