Parameterized DB Query Reader is slow

I used to use Database Looping node and it works pretty fast. Replacement for Parameterized DB Query takes for some of my queries 30 min.
Is it possible to make an option, if not return back Database Loping, to make a select of all
parameters and use them in a query as
select * from Table
where parameter in (…), where … is a select parameters.
This way it will require only one cycle to compare all the parameters per record.

Hi @izaychik63,

+1 added. (Internal reference: AP-12461)



@tobias.koetter created this component that mimics the behavior of the old DB framework, but using the nodes from the new DB framework.


This works as a hacky workaround but ideally the Parameterized DB Query Node should be adjusted or a looping node based on new DB framework introduced that also has SQL statement highlighting etc.


The reason for the slowness is quiet trivial: the Parameterized DB Query Node makes 1 query per row compared to the looping node which could do as many rows per query as your databases IN statements allow ( 1000 with oracle, AFAIK 32k with postgresql). So if you are doing 1 instead of 1000 queries the node will pretty much run 1000 times faster.

EDIT: which is another way of saying the existence of the Parameterized DB Query Node is questionable at best because you will probably almost always be faster reading out the full table and doing a join.


This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.