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
dplandry
Regular Visitor

Working with dates from multiple tables

Ok, I'm new to Power BI and am really having difficulty getting this report to work.  I have 2 tables...CUSTORDR and AR_INTRASTAT.  I'm trying to build an on-time delivery report and have the main report data pulled together, but am having trouble calculating the date differences since ship_date is in AR_INTRASTAT table and the promised and requested delivery dates are in CUSTORDR table.

 

Report columns:

Cust_ID [CUSTORDR table]

SALES ORDER #  [CUSTORDR table]

CUST_PO (Text)  [CUSTORDR table]

ITEM (text)  [CUSTORDR table]

CREATE_DATE (Date)  [CUSTORDR table]

PROM_DELIVERY (Date)  [CUSTORDR table]

REQUESTED_DELIVERY (Date)  [CUSTORDR table]

TRANSIT (DAYS)  [CUSTORDR table]

SHIPMENT_NO (Number)   [AR_INTRASTAT table]

SHIP_DATE (Date)  [AR_INTRASTAT table]

 

I need the number of days between SHIP_DATE and PROM_DELIVERY in a column and SHIP_DATE and REQUESTED_DELIVERY in another column.  Any assistance would be GREATLY appreciated.

 

Thanks

Dwayne

 

 

3 REPLIES 3
Greg_Deckler
Super User
Super User

I'm not sure how you get there with the information that you have provided. How does AR_INSTRASTAT relate to CUSTORDR? What ties a customer order to a shipment?


@ 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...

Sorry I left that out of my post..  They're joined by SALESORDER# which appears in both tables.

Hi @dplandry,

 

Could you post your table structures with some sample data in this case? It's better to share a sample pbix file.Smiley Happy

 

Regards

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.