Page 1 of 1

UniDAC dramatically slow in wireless network

Posted: Wed 16 Mar 2011 14:21
by andy_bri
Some days ago I switched my local network from cable to wireless connection. And from this moment applicatons based on UniDAC connection slowed down app. 10 times! I know, that wireless network is slower. However I tested loading 3000 records (just SELECT * FROM CUSTOMER) from local server to workstation:
- TIbDatabase and TIbDataset - below 4 seconds,
- IbExpert also loads all table records in 4 seconds,
- TUniConnection and TUniQuery/TUniTable - over 30 seconds.

What is wrong? Is there any special configuration of UniDAC connection required? All properties have default values: FetchAll is false, I am using standard TDbGrid, default index, no filters or master/details relations etc.

I am using:
- Delphi XE Professional,
- newest UniDAC version 3.60.0.16, just TUniConnection TUniTransaction and TUniQuery
- connection protocol: TCP/IP
- Windows Vista, Windows 7 and Windows XP,
- Firebird 2.5.

Posted: Fri 18 Mar 2011 07:30
by AndreyZ
Hello,

While we are looking for the possibility of testing UniDAC with wireless connection, you can try the following approaches in order to investigate this problem:
1) set the FetchAll property to True;
2) set the FetchAll property to False and play with the FetchRows property;
3) test UniDAC data loading speed without using the TDBGrid component.

Posted: Tue 22 Mar 2011 06:15
by andy_bri
Thanks for advice, but FetchRows flag manipulations did not change anything. I also tested CompressBlobMode, LongStrings, disabling DbGrid, using DataEditor for viewing fetched records and other settings - no solution found.

Last days I have made many additional tests. It looks like UniDAC works very slowly also with cable connection. Are there problems for specific routers or maybe it is very slow in every network? What are your experience?

I am using typical TP-LINK Router (Model: 150M Wireless Lite N ADSL2+ Modem Router), connection via cables. Results (TCP/IP protocol):
- IbExpert fetches 3000 records from the local server in about 1 second.
- IbDatabase / IbQuery: the same.
- UniConnection / UniQuery needs about... 11 seconds.

Am I doing something wrong?

Posted: Tue 22 Mar 2011 13:51
by andy_bri
Resolved (with help from AnyDAC support team). DeferredBlobRead flag in TUniQuery options must be set to True and fetching rows runs as quick as IBExpert and IBX.

Posted: Tue 22 Mar 2011 15:24
by AndreyZ
It is good to see that this problem was solved. If DeferredBlobRead property is set to True, all BLOB values are only fetched when they are explicitly requested. If any other questions come up, please contact us.

Posted: Tue 22 Mar 2011 17:25
by andy_bri
Ok, thank you.

Posted: Wed 21 Sep 2011 14:16
by maddn
Hi, I have the same problem but with MySQL. Is there a way to use something like DeferredBlobRead on MySQL?

Posted: Fri 23 Sep 2011 09:57
by AndreyZ
Please specify the exact operation that is slow in wireless network when you are working with MySQL. Is it reading data or updating data?

Posted: Mon 26 Sep 2011 08:33
by maddn
Hi AndreyZ I thought I can put my question right here. If you want I can also start a new Thread.

My Problem is reading data from large Tables with Blobfields. I wonder if there is an Option to deactivate reading all the blobs. Only the blob which is selected should be transferred.

Posted: Tue 27 Sep 2011 09:38
by AndreyZ
Unfortunately, UniDAC doesn't have options for MySQL that can prevent blob reading. The point is that if you put a blob field into the SELECT statement, MySQL will return this field anyway. The only way to make data reading faster for MySQL is to set the FetchAll property to False. In this case data will be fetched to a client computer only if it is requested.

Posted: Fri 30 Sep 2011 07:30
by maddn
Hi AndreyZ, thank you for your answer but now I wonder how AnyDAC does this because there my large Blob-Table opens with fetchall=true really fast.
Anyway I'll decide for UniDAC because it is much more comfortable :)

Posted: Fri 30 Sep 2011 14:38
by AndreyZ
We will investigate the problem with blob fields. As soon as we have any results we will let you know.

Posted: Mon 03 Oct 2011 08:11
by tanghz
It seems put BLOB content in another table is a safe bet for DB design. Correct me if I am wrong.

Posted: Tue 04 Oct 2011 11:27
by maddn
AndreyZ wrote:We will investigate the problem with blob fields. As soon as we have any results we will let you know.

Thanks for that!

tanghz wrote:It seems put BLOB content in another table is a safe bet for DB design. Correct me if I am wrong.
Thats right but the tablestructures are allready done for several years and infact we get no money for redesign :) :wink:

Posted: Wed 05 Oct 2011 10:27
by AndreyZ
We've checked the question about blob fields. When MySQL server is used, both UniDAC and AnyDAC fetch blob data from the server, and have almost the same performance. We are interested in finding a solution for this problem, so if you have an example that demonstrates AnyDAC not fetching blob fields from the server, please send it to andreyz*devart*com. We are looking forward to receiving this sample from you.