You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ibatis.apache.org by "Thomas Noirez (JIRA)" <ib...@incubator.apache.org> on 2005/12/02 14:49:30 UTC
[jira] Created: (IBATIS-230) Warn when two ids of a tag are identical
Warn when two ids of a <sql> tag are identical
----------------------------------------------
Key: IBATIS-230
URL: http://issues.apache.org/jira/browse/IBATIS-230
Project: iBatis for Java
Type: Improvement
Components: SQL Maps
Versions: 2.1.6
Environment: Windows XP, JDK 1.4.2, Eclipse 3.1
Reporter: Thomas Noirez
Priority: Minor
When they are two <sql> tags with the same id, the last read is the one !
but may be a warning will be usefull to say that id already exists...
--
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
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Updated: (IBATIS-230) Warn when two ids of a tag are identical
Posted by "Sven Boden (JIRA)" <ib...@incubator.apache.org>.
[ http://issues.apache.org/jira/browse/IBATIS-230?page=all ]
Sven Boden updated IBATIS-230:
------------------------------
Attachment: SqlMapParser.java
The attached file throws an exception when a duplicate <sql> occurs.
Sven
> Warn when two ids of a <sql> tag are identical
> ----------------------------------------------
>
> Key: IBATIS-230
> URL: http://issues.apache.org/jira/browse/IBATIS-230
> Project: iBatis for Java
> Type: Improvement
> Components: SQL Maps
> Versions: 2.1.6
> Environment: Windows XP, JDK 1.4.2, Eclipse 3.1
> Reporter: Thomas Noirez
> Priority: Minor
> Attachments: SqlMapParser.java
>
> When they are two <sql> tags with the same id, the last read is the one !
> but may be a warning will be usefull to say that id already exists...
--
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
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Commented: (IBATIS-230) Warn when two ids of a tag are identical
Posted by "Thomas Noirez (JIRA)" <ib...@incubator.apache.org>.
[ http://issues.apache.org/jira/browse/IBATIS-230?page=comments#action_12359421 ]
Thomas Noirez commented on IBATIS-230:
--------------------------------------
Ex. in file1 (no namespace):
<sql id="xxxCol">
col1,
col2,
col3
</sql>
In file2 (no namespace)
<sql id="xxxCol">
col1
</sql>
in file3
<select id="getXxx" resultMap="xxxResult">
SELECT
<include refid="xxxCol"/>
...
</select>
There is no warning, and the last <sql> id read is the one and I have a sql exception.
I hope it helps... ;-)
If you want my sql map files, I can send them
bye, Tom
> Warn when two ids of a <sql> tag are identical
> ----------------------------------------------
>
> Key: IBATIS-230
> URL: http://issues.apache.org/jira/browse/IBATIS-230
> Project: iBatis for Java
> Type: Improvement
> Components: SQL Maps
> Versions: 2.1.6
> Environment: Windows XP, JDK 1.4.2, Eclipse 3.1
> Reporter: Thomas Noirez
> Priority: Minor
>
> When they are two <sql> tags with the same id, the last read is the one !
> but may be a warning will be usefull to say that id already exists...
--
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
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Commented: (IBATIS-230) Warn when two ids of a tag are identical
Posted by "Sven Boden (JIRA)" <ib...@incubator.apache.org>.
[ http://issues.apache.org/jira/browse/IBATIS-230?page=comments#action_12359340 ]
Sven Boden commented on IBATIS-230:
-----------------------------------
Can you give a specific example, e.g. an SQLmap in which this happens. I tried it with duplicate procedures and select id's and e.g. with duplicate select id's you get the following exception:
"Cause: com.ibatis.sqlmap.client.SqlMapException: There is already a statement named searchDynamicEmployee2 in this SqlMap."
Sven
> Warn when two ids of a <sql> tag are identical
> ----------------------------------------------
>
> Key: IBATIS-230
> URL: http://issues.apache.org/jira/browse/IBATIS-230
> Project: iBatis for Java
> Type: Improvement
> Components: SQL Maps
> Versions: 2.1.6
> Environment: Windows XP, JDK 1.4.2, Eclipse 3.1
> Reporter: Thomas Noirez
> Priority: Minor
>
> When they are two <sql> tags with the same id, the last read is the one !
> but may be a warning will be usefull to say that id already exists...
--
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
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira