Recursive inclusions don't expand
---------------------------------
Key: IBATIS-65
URL: http://issues.apache.org/jira/browse/IBATIS-65
Project: iBatis for Java
Type: Bug
Components: SQL Maps
Versions: 2.0.9
Reporter: Rohan Lenard
Given the documentation doesn't mention this it is hard to know what is correct.
I have an SQL Map like this
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE sqlMap
PUBLIC "-//iBATIS.com//DTD SQL Map Config 2.0//EN"
"http://www.ibatis.com/dtd/sql-map-2.dtd">
<sqlMap>
<select id="getFrequencyTableData" parameterClass="java.util.Map"
resultMap="frequency-table-result">
SELECT sum(a) as a FROM tablea
<dynamic prepend="WHERE">
$externalClause$
</dynamic>
GROUP BY
<isNotNull property="timeChunkClause">
begin,
</isNotNull>
<!-- Note: upperlimit is "strictly" required - but not by MYSQL -
for HSQLDB and probably other DBs -->
lowerlimit, upperlimit
</select>
</sqlMap>
Now external clause is passed as a parameter with a value like this .
( criteria = #criteria_0# )
What I expected the SQL to end up as is
SELECT sum(a) as a FROM tablea WHERE criteria = ?
But it gets expanded as
SELECT sum(a) as a FROM tablea WHERE criteria = #criteria_0#
Shouldn't it be expanded ??
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira