Page 1 of 1

indexfieldnames and order by

Posted: Mon 18 Apr 2011 13:47
by inageib
Hello,
I set the property indexfieldnames to the ID of a table and I set the select SQL to have order by name field but the order by has no effect

I figured out that I must change indexfieldnames to sort based on the name, but I really wish to change that behavior and always make the SQL override any property in the component

thanks

Posted: Tue 19 Apr 2011 09:30
by AndreyZ
Hello,

The ORDER BY statement in your SQL code means that data will be sorted on the server. The IndexFieldNames property is used to sort data locally. If you want to sort data only on the server, you shouldn't set the IndexFieldNames property.

Posted: Tue 19 Apr 2011 09:52
by inageib
ok if I did not set IndexFieldNames will not affect on the component work for any thing ?

Posted: Tue 19 Apr 2011 11:46
by AndreyZ
If you don't set the IndexFieldNames property, IBDAC won't sort data received from the server (IBDAC retains server order).

Posted: Tue 19 Apr 2011 11:53
by inageib
Thanks alot