diff options
author | godzilla80@gmx.net <> | 2009-03-22 08:02:35 +0000 |
---|---|---|
committer | godzilla80@gmx.net <> | 2009-03-22 08:02:35 +0000 |
commit | 466c414ebc9dde38e80f20fd96fd891431404fca (patch) | |
tree | 9934bdefe395804dc334b4d12637db345f97c8b5 /tests/unit/Data/SqlMap/DynamicParameterTestMap.xml | |
parent | 1624bf7d560af5789416af904e45975618adef8c (diff) |
Fixed Issue #88 - SQLMap $Param$ re-evaluation bug
Diffstat (limited to 'tests/unit/Data/SqlMap/DynamicParameterTestMap.xml')
-rw-r--r-- | tests/unit/Data/SqlMap/DynamicParameterTestMap.xml | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/tests/unit/Data/SqlMap/DynamicParameterTestMap.xml b/tests/unit/Data/SqlMap/DynamicParameterTestMap.xml new file mode 100644 index 00000000..65a91154 --- /dev/null +++ b/tests/unit/Data/SqlMap/DynamicParameterTestMap.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="UTF-8" ?>
+<sqlMap namespace="DynamicParameterTestMap">
+ <select id="SelectStaticSql1" resultClass="string">
+ <![CDATA[
+ SELECT `teststring` FROM `dynamicparametertest1` WHERE `testname`="staticsql"
+ ]]>
+ </select>
+
+ <select id="SelectStaticSql2" resultClass="string">
+ <![CDATA[
+ SELECT `teststring` FROM `dynamicparametertest2` WHERE `testname`="staticsql"
+ ]]>
+ </select>
+
+ <select id="SelectDynamicTable" parameterClass="string" resultClass="string">
+ <![CDATA[
+ SELECT `teststring` FROM `$value$` WHERE `testname`="dynamictable"
+ ]]>
+ </select>
+
+ <select id="SelectDynamicComplex" parameterClass="array" resultClass="string">
+ <![CDATA[
+ SELECT CONCAT("##", `teststring`, "$$") FROM `$tablename$` WHERE `testname`=#testname, dbType=varchar#
+ ]]>
+ </select>
+
+ <select id="SelectNoDynamic" parameterClass="string" resultClass="string">
+ <![CDATA[
+ SELECT `teststring` FROM `dynamicparametertest1` WHERE `testname`=#value, dbType=varchar#
+ ]]>
+ </select>
+
+</sqlMap>
\ No newline at end of file |