Sort grid by selection field text

SOLVED

CRM 2020 R1 - I have a custom entity with a selection field in the list/grid page.  I want to sort the grid by the selection field text, but the grid sorts it by the field value (ie the code).  The codes are all numeric (imported from old system) so the grid appears to be in random order when it is 'sorted'.

How can I sort the grid by the selection field text rather than code?

Parents Reply Children
  • 0 in reply to Guy Cecil

    Yes, that's what I'm planning.  There's also the issue of converting the data from the old app to import the historical info - a lot of lookup tables and so on but not impossible.

    I'm also considering joining Custom_Captions into the view.  I can then have the translations in the grid which should sort correctly.  That will work so long as there aren't any users that use a different language - probably ok in this case.  Or I could change the sql for the grid dynamically in the asp to include the user's language translation - that might work.

  • +1 in reply to Paul C
    verified answer

    I've tested joining Custom_Captions into the view and then having the translations (Capt_UK) instead of the selection field in the grid and it works well.