Can table be sorted in reverse order

Discussion of open issues, suggestions and bugs regarding Virtual Data Access Components for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
softsmith
Posts: 19
Joined: Fri 27 Jan 2012 01:17

Can table be sorted in reverse order

Post by softsmith » Tue 20 Mar 2012 08:37

I often need to sort a VirtualTable in reverse sort order.
I set the IndexfieldNames to the field I want to sort, but is there an option to sort it from Z to A instead of A to z ?

Thanks

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Tue 20 Mar 2012 09:14

Hello,

For specifying sorting order, besides the field name in the IndexFieldNames property, you should specify the sorting order (asc or desc), for example

VirtualTable.IndexFieldNames := 'NAME desc';

softsmith
Posts: 19
Joined: Fri 27 Jan 2012 01:17

Post by softsmith » Tue 20 Mar 2012 19:22

Thank you for the information. Just what I wanted to hear. You have made my day.

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Wed 21 Mar 2012 07:21

Hello,

If you have any other questions, feel free to contact us.

Post Reply