How simply sort a grid by any column in a bus view Find/Browse

tritone

Member
Hi

All I want to do is re-sort a grid using an alternate column in the business view attached to my grid.

Let's say the grid is sorted by column 1 from my business view V55MYFILE. I want to re-sort by column 2. So in the Find button event rules, I used
1) Clear Sequence (FC GRid)
2) Set Sequence (FC grid, table name=F55MYFILE, alias=Column2 from F55MYFILE, <ascending>). If I click Find the grid continues to remain sorted by column 1.

This seems so simple and no matter what I do including deleting the spec files, the grid remains sorted by column 1.

Does anyone have an example of code and the location in the event rules in which I should place it?

Thanks
 
What you're trying should work... and does. A couple of things to check:

1) Make sure you're only using the DD alias and not including the table prefix
2) Have you turned on debug logging to see the generated SQL statement?
3) Log off and back on just in case you have your form specs cached
 
Jeremy you are a genius!
OMG! That was it. Under the "alias" in the set sequence statement, I was selecting the column from the list of business view columns. When I chose <literal> instead and typed in the DD alias for the column, the statements worked as advertised.
I guess in retrospect, alias really means DD alias.

Thank you so much for your quick response. I searched for such a long time for examples of doing it correctly nd found none.
 
Back
Top