cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
spud Frequent Visitor
Frequent Visitor

first product ordered

 I would like your help:

 

short hypothetical example

 

a vendor sells the following items:

cherries code 283

apples   code 282

oranges code 111

 

A customer orders cherries and apples all of the time

 

Suddenly the customer orders oranges- how could you set something up to find if a customer ordered a new item such as oranges

 

1 REPLY 1
Super User
Super User

Re: first product ordered

@spud I assumed there is order date in the data, add following column to identify when product was ordered first time.

 

Is this first order = 
VAR __itemsOrders = CALCULATETABLE( VALUES( Table3[Product] ), FILTER( ALL( Table3 ), Table3[OrderDate] < EARLIER( Table3[OrderDate] ) ) )
RETURN
IF( NOT Table3[Product]  IN __itemsOrders, "Yes" )





Did I answer your question? Mark my post as a solution.

Proud to be a Datanaut! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.





Helpful resources

Announcements
Can You Solve These Challenge

Challenge: Can You Solve These?

Find out how to participate in the first Power BI 'Can You Solve These?' challenge.

New Badges

Incoming: New and Improved Badges

Exciting news: We've given our badges an overhaul and added brand news ones.

Ask Amir Anything

Exclusive LIVE Community Event No. 2 – Ask Amir Anything

Next in our Triple A series: Ask Amir Netz questions about the latest updates, features and future.

Analytics in Azure virtual event

Analytics in Azure virtual event

Experience a limitless analytics service built to ingest, prep, manage, and serve data for immediate use in Power BI.

Users Online
Currently online: 330 members 3,328 guests
Please welcome our newest community members: