Forum Discussion
- ArshadKhwajaQrew CommanderNeed some help here.
- GauravSharma3Qrew Commander> and I need a certain order.
What type of certain order do you want?
Thanks,
Gaurav - ArshadKhwajaQrew CommanderIt is sorting in alpha order at the moment, I would like to have an order predefined which can best achieved by adding a prefix number but I am preferring not to have unsightly numbers in values.
- QuickBaseCoachDQrew CaptainI that the only way to control the sort without cheating uf if the sort Fields happen to be from multiple choice fields where the choices are contained in the field properties.
Aside from that the typical cheats are having a formula field to number the choices or else, and I often do this, is to have a cheat formula field which prefaces the words with an appropriate number of leading spaces to get the sort order correct. - ArshadKhwajaQrew CommanderThanks a lot Mark. The first option could work but the choices are linked to a table (banners) created by you.
So I am really left with the good old option of creating a formula field. And the another formula field to remove the numbering. - QuickBaseCoachDQrew Captainso why not load the Banner table with the sorted names in addition to the clean name.
ie if you wanted Woolworths to sort first, you would load this new field in that table as " Woolworths" ( you would not actually load the quotes, but I'm showing that you would load with a leading space as spaces sort first). The field would be called [Banner(Sorted])
Then just look that up to any table where you need a sorted banner for summary reports. - ArshadKhwajaQrew CommanderThanks. This is all good. appreciate your help.
- LutherMillerQrew MemberHere is a trick that worked for me.
Let's say you have [Name] which is the text you want in the report, but you want to sort it by another field [Name Sort Ordinal]. Create a Formal - Rich Text field [Display] like this and use it instead of [Name]:"<span data-ord='" & [Name Sort Ordinal] & "'>" & [Name] & "</span>"
You might need to pad the ordinal with spaces or zeros if you have numbers with more than 9 values etc. because this will be sorted as text, not as numbers.
This works because the attribute in the span tag is not displayed, but it will be part of the text that Quick Base sorts for the report, and the attribute comes before the actual display text. Only the text part between the <span></span> tags will actually be displayed.