CtrlADO parallel SQL-Queries...

Discussion about recent product features & solutions!
3 posts • Page 1 of 1
vogler
Posts:122
Joined: Thu Oct 28, 2010 8:32 am

CtrlADO parallel SQL-Queries...

Post by vogler »

Default behaviour of the CtrlADO extension is to serialize queries (DMLs/DDLs as well)! Even if you use different database connections!!!
If you have more threads using different database connections in your control they will not be executed in parallel!
=>So, one long-running-query will block all other (query)threads :-(

Add "parallelCtrlADO = 1" to your config at the [general] section to get rid of this behaviour!

Of course commands sent to one (for example global) database connection will be serialized (one database connection can only perform one action, it is one communication channel to/from the server(process))

aorange
Posts:147
Joined: Thu Nov 04, 2010 10:07 am

Re: CtrlADO parallel SQL-Queries...

Post by aorange »

Cool, now I just need our ADO to run faster... any tips/tricks on that???

vogler
Posts:122
Joined: Thu Oct 28, 2010 8:32 am

Re: CtrlADO parallel SQL-Queries...

Post by vogler »

what is too slow?

a) queries => see/use rdbSelect (rdb.ctL) => this will use dbGetResult => this will give you the result of a query directly into a table (dyn_dyn_anytype), don't use dbOpenRecordset, dbMoveNext, dbGetField, reading each item separately in ctrl... this could be very slow for big resultsets and or when you query a lot of columns!..

!!BUT!! be carefully not to pass a query with a resultset of millions of rows ;-) => you will get it into a dyn_dyn_ => memory!

b) dml's => see/use rdbExecute (rdb.ctl) => you can pass a dyn_string => this will use the dbBulkCommand => no loops in ctrl.., no dbStartCommand, dbExecuteCommand, dbFinishCommand...

3 posts • Page 1 of 1