The SourceDbQuery Actor is used in the Broadway populations to query the source data. The Actor executes the query defined in the population flow, appended with a dynamically generated WHERE clause.
The server generates this WHERE clause automatically before execution. It incorporates the keys and values passed from the parent_rows output object of the PopulationArgs Actor.
Starting from Fabric V8.4, the structure of this generated WHERE clause is determined by the Parent Rows Grouping parameter located in the Fabric properties section of the Interface Type definition for JDBC.
The following table explains how each Parent Rows Grouping setting impacts the generated SQL query structure. The resulting query depends on the number of input keys and whether those keys contain multiple values.
The choice between OR and IN significantly impacts how the database engine parses and executes a query.
Generally, the IN operator is more efficient for large datasets because many database optimizers treat it as a single operation that can be sorted or evaluated against an index more quickly than multiple OR conditions.
While OR is the default for most database types, it can lead to slower performance as the number of values increases, as the engine must evaluate each condition sequentially.
Using IN with "Tupling" allows for more concise filtering on composite keys, though it requires support from the underlying database.
The SourceDbQuery Actor is used in the Broadway populations to query the source data. The Actor executes the query defined in the population flow, appended with a dynamically generated WHERE clause.
The server generates this WHERE clause automatically before execution. It incorporates the keys and values passed from the parent_rows output object of the PopulationArgs Actor.
Starting from Fabric V8.4, the structure of this generated WHERE clause is determined by the Parent Rows Grouping parameter located in the Fabric properties section of the Interface Type definition for JDBC.
The following table explains how each Parent Rows Grouping setting impacts the generated SQL query structure. The resulting query depends on the number of input keys and whether those keys contain multiple values.
The choice between OR and IN significantly impacts how the database engine parses and executes a query.
Generally, the IN operator is more efficient for large datasets because many database optimizers treat it as a single operation that can be sorted or evaluated against an index more quickly than multiple OR conditions.
While OR is the default for most database types, it can lead to slower performance as the number of values increases, as the engine must evaluate each condition sequentially.
Using IN with "Tupling" allows for more concise filtering on composite keys, though it requires support from the underlying database.