| SQLUnit User Guide | ||
|---|---|---|
| <<< Previous | Using variables | Next >>> |
You can also set the value for a group of variables using the non-scalar form of the set tag, shown below, which will set the value of ${myquery.col1} to the value returned from the SELECT statement.
<set name="${myquery}">
<sql><stmt>select col1 from mytable where col2=45</stmt></sql>
<result>
<resultset id="1">
<row id="1">
<col id="1" name="c1" type="INTEGER">${col1}</col>
</row>
</resultset>
</result>
</set>
|
| <<< Previous | Home | Next >>> |
| Using variables | Up | Setting explicitly from Java method call |