#12 Bad example of an SQL generator in the manual

open
Nikita
Bug (17)
5
2011-10-08
2011-10-07
Michael
No

This example is given in the documentation as an example of a slow generator. This particular SQL will continuously pull the same name to use as a value to insert, while it should probably pull a random value from the table instead
<!-- For each row generated this field will get a name from the names table.
This generator will be slow - names are selected one at a time. -->
<field name= "name" type= "VARCHAR(128)" >
<data type= "SQL" >
<attr name= "sql" >
SELECT name FROM db2inst1.names FETCH FIRST 1 ROW ONLY
</attr>
</data>

Discussion

  • Nikita
    Nikita
    2011-10-08

    • assigned_to: nobody --> npchelin