Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
ADSL
Post Prodigy
Post Prodigy

Sorting the Column Name

Hi BI Community Team,

 

I have created the new column name "time session" but after tried to build the visual and it didn't sort/range as the screenshot below.

2023-07-22_17-01-19.png

Any suggestion to sort/rang it?

 

Thanks and Regards,

1 ACCEPTED SOLUTION
olgad
Resident Rockstar
Resident Rockstar

Hi, create another column

 

Time Session_Index = SWITCH(TRUE(),
[Log_In] < TIME(8,0,0), 1,
[Log_In] < TIME(12,0,0), 2,
[Log_In] < TIME(13,30,0), 3,
[Log_In] < TIME(17,30,0), 4,
[Log_In] < TIME(21,0,0), 5, 6)
 
Then, click on the first column, go to column tools, select sort by column and sort by time_session_index

DID I ANSWER YOUR QUESTION? PLEASE MARK MY POST AS A SOLUTION! APPRECIATE YOUR KUDO/LIKE!
PROUD TO BE A SUPER USER!
Best Stories, Interesting Cases: PowerBI Storytime Newsletter
Linkedin Profile: Linkedin
YouTube Channel: PowerBI Storytime

View solution in original post

2 REPLIES 2
olgad
Resident Rockstar
Resident Rockstar

Hi, create another column

 

Time Session_Index = SWITCH(TRUE(),
[Log_In] < TIME(8,0,0), 1,
[Log_In] < TIME(12,0,0), 2,
[Log_In] < TIME(13,30,0), 3,
[Log_In] < TIME(17,30,0), 4,
[Log_In] < TIME(21,0,0), 5, 6)
 
Then, click on the first column, go to column tools, select sort by column and sort by time_session_index

DID I ANSWER YOUR QUESTION? PLEASE MARK MY POST AS A SOLUTION! APPRECIATE YOUR KUDO/LIKE!
PROUD TO BE A SUPER USER!
Best Stories, Interesting Cases: PowerBI Storytime Newsletter
Linkedin Profile: Linkedin
YouTube Channel: PowerBI Storytime

Hi @olgad,

 

Thank you very much for your helpful feedback.

 

Best Regards,

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.