We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
Hi All,
I have a virtual table
_Table = GENERATE(
SUMMARIZECOLUMNS(ActivitySheet[StartTime2], ActivitySheet[EndTime2], ActivitySheet[UserID], ActivitySheet[TransactionType], ActivitySheet[BranchID], ActivitySheet[ActivitySheetDate]),
FILTER(VALUES(TimeTable[Time]),
TimeTable[Time] >= ActivitySheet[StartTime2] && TimeTable[Time] <= ActivitySheet[EndTime2])
)
The virtual table provides all the times between my StartTime2 and EndTime2 Values from my ActivitySheet table using the TimeTable.
I need to create a messure using the virtual table to show when each person worked.
Current:
Expected Output:
[ActivitySheet] - Sample
| ActivitySheetDate | UserID | StartTime2 | EndTime2 | TransactionType |
| 4/26/2021 | IGARCIA | 7:53:00 AM | 8:41:00 AM | ORD.PICK |
| 4/26/2021 | IGARCIA | 8:41:00 AM | 8:41:00 AM | OTHER |
| 4/26/2021 | IGARCIA | 8:41:00 AM | 8:42:00 AM | OTHER |
| 4/26/2021 | IGARCIA | 8:42:00 AM | 10:50:00 AM | ORD.PICK |
| 4/26/2021 | IGARCIA | 10:50:00 AM | 1:18:00 PM | WHSE.PICK |
| 4/26/2021 | IGARCIA | 1:18:00 PM | 2:58:00 PM | ORD.PICK |
| 4/26/2021 | IGARCIA | 2:58:00 PM | 3:01:00 PM | ORD.PICK |
[TimeTable] - Sample
TimeTable is in a relationship with [ActivitySheet] on 'TimeTable'[Time] One to 'ActivitySheet'[Startime2]' Many
| Time | Hour | Minute | Hour Number | Next Hour | PeriodSort | TimeKey | 10Min |
| 8:04:00 AM | 8:00:00 AM | 4 | 8 | 9:00:00 AM | 2 | 804 | 0 |
| 8:05:00 AM | 8:00:00 AM | 5 | 8 | 9:00:00 AM | 2 | 805 | 0 |
| 8:06:00 AM | 8:00:00 AM | 6 | 8 | 9:00:00 AM | 2 | 806 | 0 |
| 8:07:00 AM | 8:00:00 AM | 7 | 8 | 9:00:00 AM | 2 | 807 | 0 |
| 8:08:00 AM | 8:00:00 AM | 8 | 8 | 9:00:00 AM | 2 | 808 | 0 |
| 8:09:00 AM | 8:00:00 AM | 9 | 8 | 9:00:00 AM | 2 | 809 | 0 |
| 8:10:00 AM | 8:00:00 AM | 10 | 8 | 9:00:00 AM | 2 | 810 | 10 |
| 8:11:00 AM | 8:00:00 AM | 11 | 8 | 9:00:00 AM | 2 | 811 | 10 |
Hi @EnrichedUser ,
This could be related to DAX performance, you can refer to this blog:https://maqsoftware.com/expertise/powerbi/dax-best-practices
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
I think you always post the same thing and maybe it sometimes helps people, but your response doesnt relate to anything in this request and is too generic to be useful.
and yes ive read that before.
I was able to get it working using the below messure and making the table a calculated table instead of a virtual one
Working Segment =
IF(COUNT('Test 2'[Time])>0,
1,
BLANK()
)
It nearly doubled the size of my file and is not a great long term solution.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 57 | |
| 38 | |
| 33 | |
| 19 | |
| 16 |
| User | Count |
|---|---|
| 67 | |
| 66 | |
| 40 | |
| 34 | |
| 25 |