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
erhan_79
Post Prodigy
Post Prodigy

Formula Help - (Delivery Performance Calculating)

Dear All ,

 

i need your kind supports about below problem 

 

I have two tables one of them shows purchasing orders and the other one shows delivery orders which are related with purchase orders.

 

I would like to calculate delivery performance for each purchase order's first scheduled delivery time based on months .And at the same time i would like to calculate all delivery performance for each purchase order.

 

İ created a pbix file and did somethings but i could not catch what i find and i could not solve the problem.Could you create for me the formulas and tables .Or how can you help me ?

 i am attaching here as below screenshot infact what i want to see on power bi screen with my comments.

 

Also for to be more easy to solve the problem  i am sharing with you  the pbix file 's link and the source excel file's links  under screen shot.You will see the difference between my request and the created pbix file when you open my pbix file .thanks in advance 

 

yau can see at below which visual tables i would to see on power bi.

 

 

 

Capture6.JPG

 The file link : 

 

https://drive.google.com/drive/folders/13DsWGv_eeTAMtUUF9Hqs8lV2zDXzZYIb?usp=sharing

 

 

Capture7.JPG

 

1 ACCEPTED SOLUTION
v-eachen-msft
Community Support
Community Support

Hi @erhan_79 ,

 

For your first visual, you could create a measure as a condition in the filter pane.

Measure =
VAR a =
    SELECTEDVALUE ( Purchase[Purchase Date] )
VAR b =
    SELECTEDVALUE ( Delivery[Delivery Date] )
RETURN
    IF ( a = b, 1, 0 )

For your second visual, you could create two measures to replace original columns.

_Delivery Quantity =
CALCULATE (
    SUM ( Delivery[Delivery Quantity] ),
    ALL ( Delivery[Delivery Date] ),
    FILTER (
        Delivery,
        Delivery[Vendor Name] = SELECTEDVALUE ( Delivery[Vendor Name] )
    )
)
_Order Quantity =
CALCULATE (
    SUM ( Purchase[Order Quantity] ),
    ALL ( Delivery[Delivery Date] ),
    FILTER (
        Delivery,
        Delivery[Vendor Name] = SELECTEDVALUE ( Delivery[Vendor Name] )
    )
)

Then show the result which is not blank in the filter pane.

1-1.PNG1-2.PNG

Here is my test file for your reference.

 

Community Support Team _ Eads
If this post helps, then please consider Accept it as the solution to help the other members find it.

View solution in original post

2 REPLIES 2
v-eachen-msft
Community Support
Community Support

Hi @erhan_79 ,

 

For your first visual, you could create a measure as a condition in the filter pane.

Measure =
VAR a =
    SELECTEDVALUE ( Purchase[Purchase Date] )
VAR b =
    SELECTEDVALUE ( Delivery[Delivery Date] )
RETURN
    IF ( a = b, 1, 0 )

For your second visual, you could create two measures to replace original columns.

_Delivery Quantity =
CALCULATE (
    SUM ( Delivery[Delivery Quantity] ),
    ALL ( Delivery[Delivery Date] ),
    FILTER (
        Delivery,
        Delivery[Vendor Name] = SELECTEDVALUE ( Delivery[Vendor Name] )
    )
)
_Order Quantity =
CALCULATE (
    SUM ( Purchase[Order Quantity] ),
    ALL ( Delivery[Delivery Date] ),
    FILTER (
        Delivery,
        Delivery[Vendor Name] = SELECTEDVALUE ( Delivery[Vendor Name] )
    )
)

Then show the result which is not blank in the filter pane.

1-1.PNG1-2.PNG

Here is my test file for your reference.

 

Community Support Team _ Eads
If this post helps, then please consider Accept it as the solution to help the other members find it.

@v-eachen-msft  thank you very much for your help , it helped me too much .Also i need one more thing too

 

 

i would like to show first scheduled delivery  performance with with gauge visual (as in below picture's performance ) , but when i select performance gauge is showing all month's performance , i just want to show only first scheduled month's performance , how can i show it ? Capture11.JPG

 

 

 

 

 

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.