Hi!
I need to execute a query when a form is shown. The mySQL-Server is very slow. When MyQuery.Open is executed the form is blocked for some seconds.
Is there a possebility to execute the query in background and get notified (event?) when the data are fetched?
Thanks for Help,
and sorry for the poor Englisch, it's not my native language.
Best Regards,
Sascha
MyQuery.Open takes too long
You can try using FetchAll=False mode. The record set opens quickly and gets browsable and editable immediately after open, data is fetched on the users request (calling Next, Last, Locate methods etc.). But this mode has some restrictions. Please read MyDAC help for more information.
Another way of solving this problem is creating multithreaded application and handling background queries manually. But you have to use one MyConnection instance per thread.
Another way of solving this problem is creating multithreaded application and handling background queries manually. But you have to use one MyConnection instance per thread.