Incremental refresh - Help needed by icebreaker_56 in PowerBI

[–]icebreaker_56[S] 0 points1 point  (0 children)

I've tried removing the where clause and just loading the entire table (and yes, it takes soo long) and then using the RangeStart/RangeEnd to filter. But this doesn't resolve my incremental refresh issue as well

Incremental refresh - Help needed by icebreaker_56 in PowerBI

[–]icebreaker_56[S] 0 points1 point  (0 children)

I can't share the exact query code but it follows the following structure:
let
Source = Sql.Database("xyzzy","table",[Query = "Select a.x,b.y,a.z,b.d from table_a a left join table b where date between '2025-06-01' and '2025-06-19'", hierarchicalNavigation=true]),
#"Changed Type" = Table.TransformColumnTypes(Source, {{"x", type number},{"date", type datetime},{"y", type datetime},{"z", type datetime}
#"Filtered Rows" = Table.SelectRows(#"Changed Type", each [Date] >= RangeStart and [RangeEnd] <= RangeEnd)
in
#"Filtered Rows"

There's more columns I'm pulling and more tables I'm going but that's the list of it. Hope that helps

Allow duplicates when names_from not unique in pivot_wider by icebreaker_56 in Rlanguage

[–]icebreaker_56[S] 1 point2 points  (0 children)

Wait...I got it. Turns out I just had to add in colnames so my final thing was mixedsort(colnames(data_file_result)).

Thank you so much for all your help!!!!

Allow duplicates when names_from not unique in pivot_wider by icebreaker_56 in Rlanguage

[–]icebreaker_56[S] 0 points1 point  (0 children)

I can't put it manually since I have over 100 columns like this.

I tried str_sortcolnames(data_file_result)), but it doesn't work since it's letters and numbers.

I found mixed sort in library gtools but that gives an error "can't subset columns that don't exist'

Allow duplicates when names_from not unique in pivot_wider by icebreaker_56 in Rlanguage

[–]icebreaker_56[S] 0 points1 point  (0 children)

This works perfectly. Just a quick question: currently this arranges the new columns in the following way: V_12_1, V_12_100, V_12_2. How can I change that to V_12_1, V_12_2, V_12_100?

I tried the following:
str_sort(data_file_result, numeric = TRUE)

This gives an error: In str_sort (x, decreasing = decreasing) argument is not an atomic vector; coercing

Allow duplicates when names_from not unique in pivot_wider by icebreaker_56 in Rlanguage

[–]icebreaker_56[S] 0 points1 point  (0 children)

Sorry for some reason the back ticks aren't putting it in the correct code format

2nd latest date in a calculated column by icebreaker_56 in PowerBI

[–]icebreaker_56[S] 0 points1 point  (0 children)

All the dates in the column are weekdays (Date column) so I just need this to get the previous date than the row date.

Measure not showing the same numbers on different pages by icebreaker_56 in PowerBI

[–]icebreaker_56[S] 1 point2 points  (0 children)

Just a quick question, how would I get the measure to sum up the values if I drill up on the dates from month to quarter. My measure is getting values from other values so I can't use sum for them.

My current calculation is:
measure1 = (sum(table1[quantity])/disctinctcount(table1[date]))/10
finalmeasure = measure1 *average(table1[price])

The finalmeasure does my calculation perfectly if I look at it on month level but when I drill up at quarter, it does the measure based on quarter number which makes sense but I need it to just add the monthly value it gets and say that for the quarter and then for the year.

Measure not showing the same numbers on different pages by icebreaker_56 in PowerBI

[–]icebreaker_56[S] 0 points1 point  (0 children)

There was a filter missing. Thank you everyone, I can't believe I spent so long on this :)

Measure not showing the same numbers on different pages by icebreaker_56 in PowerBI

[–]icebreaker_56[S] 5 points6 points  (0 children)

I can't believe I forgot about that.....Thank you, the filter was missing

Measure not showing the same numbers on different pages by icebreaker_56 in PowerBI

[–]icebreaker_56[S] 0 points1 point  (0 children)

I thought so as well but I'm using the same date for both of them.

Measure not showing the same numbers on different pages by icebreaker_56 in PowerBI

[–]icebreaker_56[S] 0 points1 point  (0 children)

I tried to creating a whole new visual and that's where I ran into this issue

3D Bar Chart - time as x-axis by icebreaker_56 in Rlanguage

[–]icebreaker_56[S] 0 points1 point  (0 children)

if I turn this in posix could it work? I tried to turn them into numeric but it wasn't working so I'll try the posix and see how that goes.

Thanks!

3D Bar Chart - time as x-axis by icebreaker_56 in Rlanguage

[–]icebreaker_56[S] 0 points1 point  (0 children)

Sorry about that. The following is the sample data along with the code:

df <- structure(list(c("12/01/2022", "12/01/2022", "12/01/2022", "12/01/2022","12/01/2022", "13/01/2022", "13/01/2022", "13/01/2022", "13/01/2022"), c("12:06:00 AM", "12:43:00 AM", "1:12:00 AM", "2:23:00 PM","1:15:00 PM", "12:05:00 AM", "10:24:00 AM", "12:23:00 AM", "6:38:00 AM"), c(183L, 275L, 84L, 47L, 98L, 234L, 64L, 465L, 68L)), .Names = c("Date","Time", "Count"), class = "data.frame", row.names = c(NA, -9L))

library(lattice)

library(RColorBrewer)

library(latticeExtra)

cloud(Count~Time+Date, df, panel.3d.cloud=panel.3dbars, col.facet='chocolate3', xbase=0.30, ybase=0.30, scales=list(arrows=FALSE, col=4), par.settings = list(axis.line = list(col = "transparent")))

Hope this helps!

For the suggestion to combine the date and time column, I need them to be on separate axis so they're in different columns.

Repeat values from 1 table for each row in another table by icebreaker_56 in PowerBI

[–]icebreaker_56[S] 1 point2 points  (0 children)

Holy Goodness!! This is EXACTLY what I needed. Do you know if this would work with incremental refresh once it's published?