How to pass a key in the query while creating a database check point?
Hi, Would be great if you could let me know how to pass a key in the query while creating a database check point? My key value is stored in a variable in the script.
In short, what I want to know is:
myVar='keyvalue'
select * from myTable where myKey='keyvalue';
Instead of specifying the query like select * from myTable where myKey='keyvalue'; in the database checkpoint, I want to use the variable myVar so that the 'keyvalue' can be dynamically attributed. Thanks.
RE: How to pass a key in the query while creating a database check point?
I don't think it is possible tp parametrize a checkpoint. A db checkpoint says you have a expected set of data (which is obtained only from a query with hard coded values) and this is compared with the run-time query execution(which is dynamic).
I do not know if you did find a solution to the problem you have posted. Do let us know if there is any solution to parametrizing or some other way to go around the problem.
RE: How to pass a key in the query while creating a database check point?
While a database checkpoint is created the select statement gets stored in "Source".
So for parameterizing it Create a checkpoint initially in the normal flow with a constant value.....and then parametrize it by updating with SETTOPROPERTY command as shown below....
a "select * from tablename where colname '" & datatable("colnameinqtp" dtlocalsheet) & "'