How do I change the order of categories?

I currently have an input that is linked to two categories via a google sheet dataset: Billing Class and Location.

In my model, when I add the input it shows the categories as a hierarchy “Enrollment > Billing Class > Location”.

I would like to change the hierarchy order so that it goes “Enrollment > Location > Billing Class.”

How would I go about doing that?

image

Hi @Tierney_Santoro, Great question! Currently, we’re not preserving the order of categories coming from a data source (I just created a task for our engineering team to fix that).

Here’s a hack that should work for now. Create a variable called “Category Order Hack”, set the value to “0”, and then apply all the categories in the right order.

Then in your variable that has the incorrect order just add “+ {{Category Order Hack}}” to the formula.

1 Like

Hi @Lukas - has there by any chance been an update to this?

Best,
Anton

Hey Anton, No update yet unfortunately. The hack is still the best way to do it. We’ll update you on this thread when we have a better way. Sorry!