I have a grid datawindow with some headers and columns in Powerbuilder 10.5.
Using the pfc all my headers have identical names as the columns and end with _t as indicated.
At runtime when I click on some headers the rows are not sorted correctly.
After the first click the rows are sorted in ascending order.
After the second click the rows are sorted in descending order.
After the third click the rows are sorted in ascending order as the first click.
After the fourth click the rows seem to be sorted in descending order but the first row is not the same as in the second click sorting.
Though for some headers sorting works correctly. What might be the problem?
When you sort on a column that has more than one row with the same value, the order of the rows with the same value is undefined. In technical terms the sort in the DataWindow is not a Stable Sort.