Expensive? - ORDERBY(REF_ROWS(), [datetime_column], TRUE)

How much weight would this add, should I construct it differently?
ORDERBY(REF_ROWS(), [datetime_column], TRUE)

0 23 1,008
23 REPLIES 23

Steve
Platinum 4
Platinum 4

Beware:

Gotcha, I usually try and leave it alone because of thisโ€ฆ

So what is a good way to order a REF_ROW? I have multiple dropdowns for employees, zones, locations, departments, positions, etc and they are all in the order added to our database. I would like them in ascending order.

Thanks.

This isnโ€™t related to the auto-generated REF_ROWS column.
To change the order of the items in the dropdowns on your Ref-type columns, you should use an ORDERBY expression in valid_if.

Assuming these are Ref-type columns, this is a key vs label situation. You just need to change which column in the referenced table is set as the Label.

Awesome! This worked by using: ORDERBY(Employee[id], [name])
In the Valif If section.

3X_7_e_7ee1498dbdbe8fb3c2595c3cb3c5df132ceb93ca.png

Is there any way to display more? Changing the label displays the vehicle now, but since we operate in multiple states, you donโ€™t want to assign a vehicle from another location.

Alsoโ€ฆ THANK YOU! I appreciate this.

Read the article I linked

HOW I MISSED THAT IS BEYOND ME! LOLLLL

Thank you

Create a Virtual Column and concatenate the info that you want to show as a label in your dropdown and set this Virtual column as the label for that table. .i.e.
[State]&"-"&[VehicleName]

Ok cool, thanks @LeventK

@wrodriguez youโ€™re welcome, itโ€™s my pleasure. Kudos should go to @Marc_Dillon

@LeventK @Marc_Dillon

Not sure if I missed something.

I crated a virtual column and added the expression below:

3X_d_f_df6efe1ce57de01cdfdd8600809a629bbc6d55e6.png

I made it the label and made sure nothing else was marked as a label.

The dropdown now only shows the VIN.

Should I be referencing that table instead of a view of that table?

Can you post a screenshot from your tableโ€™s structure please?

Aw man that would be like 6-7 screenshots. One moment.

Iโ€™m interested only with the table that contains your location and vehicle type/name table.

Yea that is the main table that holds all of our vehicles.




This is the column from FleetRequest I am needing the vehicle from VehicleAsset:

This is the slice:

[Vehicle] virtual column is missing in your slice column setup. As the label column is missing, itโ€™s showing the Key column value only, which is your VIN number.

This was the final touch.

Much appreciated. You sir are a gentleman and a scholar lol

Thanks

Glad to hear that your problem is solved. Youโ€™re welcome, itโ€™s my pleasure.

Glad youโ€™re back bud! Missed ya!

I also would like to be able to pick what is displayed in the dropdown. I have one that is referencing a slice that shows specific things, but the dropdown only shows the key for the table.

It basically shows available vehicles so we can assign one to a request. The dropdown shows the key, which is the VIN. No way to know what kinda vehicle it is.

Okay it looks like it works if I donโ€™t use the slice. I donโ€™t think the CONCATENATE is passed on through the slice. Maybe I can just use something else to narrow it down instead of the slice.

Top Labels in this Space