I have the following code:
controller.find();
order_lines_to_order_header.shipto_customer = 260;
controller.search();
controller.sort(‘order_number desc’);
without the sort line, this take about 3 seconds to display the 60 records that match the shipto. when I add the sort statement, it takes about 30 seconds for the form to be displayed. (there are about 30,000 rows in the table).
Thanks
Bruce
Hardware?
OS?
Database?
In Client or in Developer?
db = mssql 2000 on a very fast dual processor, raid, etc.
servoy 2.2 on mac 10.4 2 gig ram
bruce
first of all do this:
controller.find();
order_lines_to_order_header.shipto_customer = 260;
controller.sort(‘order_number desc’);
controller.search();
So first set the sorting before you do search. Or else 2 queries wil be fired.
second do you have an index on order_number?
If you fire that query. Can you see in the admin pages (db performance) what the query really does cost?