Screenshot from Semantic Model
I’m working in a Microsoft Fabric Semantic Model (same behavior as Power BI Desktop model) and I’m trying to sort one column by another using the Sort by column option.
I have a dimension column (e.g. dim_hourlyband) and a numeric column (SortKey) in the same table. In the model, I set:
dim_hourlyband→ Sort by column → SortKey
But in the report visuals, the categories are not respecting the SortKey order. Instead, they appear in alphabetical order or by default sort.
What I have checked
- Both columns are in the same table.
- SortKey is a Whole Number data type.
- No duplicate or ties in the sort order.
- I already confirmed the “Sort by column” is set in Model view (see screenshot).
- I also queried the model metadata using DAX Studio DMV (TMSCHEMA_COLUMNS) to confirm which column is used as the sort-by column for this table. It shows SortKey is not set correctly — but in the model set correctly.
Expected The HourlyBand should follow the SortKey order (e.g. 1,2,3,4,5) in visuals.