The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hello, i have this file where i have this info:
I need calculate different, for each orderid, from start time (have number 0 on colum number) and end (have mx number for this orderid on column number) in minutes.
I try to create two colum:
1) Start Date
Hi @lifesafari ,
Can you share sample data and the results you are hoping for? Show it as a screenshot or excel. Or a sample pbix after removing sensitive data. We can better understand the problem and help you.
Best Regards,
Yulia Yan
Hello @lifesafari,
Can you please try this approach:
DateDiffMinutes =
VAR MaxNumberPerOrder = SUMMARIZE(YourTable, YourTable[orderid], "MaxNum", MAX(YourTable[number]))
VAR StartDate = MINX(FILTER(YourTable, YourTable[Numero] = 0), YourTable[Data e ora creazione])
VAR EndDate = MAXX(FILTER(YourTable, YourTable[orderid] IN SELECTCOLUMNS(MaxNumberPerOrder, "OrderID", YourTable[orderid]) && YourTable[Numero] = [MaxNum]), YourTable[Data e ora creazione])
RETURN
DATEDIFF(StartDate, EndDate, MINUTE)
Hello this not working.
User | Count |
---|---|
15 | |
8 | |
6 | |
6 | |
6 |
User | Count |
---|---|
23 | |
14 | |
13 | |
8 | |
8 |