You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ibatis.apache.org by "Ron Grabowski (JIRA)" <ib...@incubator.apache.org> on 2005/04/21 17:06:26 UTC

[jira] Created: (IBATISNET-45) Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true

Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true
-----------------------------------------------------------------------------------------------------

         Key: IBATISNET-45
         URL: http://issues.apache.org/jira/browse/IBATISNET-45
     Project: iBatis for .NET
        Type: Bug
 Environment: DataMapper: 1.1.458.0
    Reporter: Ron Grabowski
 Assigned to: Gilles Bayon 
    Priority: Minor


If I try to access a result map in a different namespace using this syntax:

<sqlMap namespace="XYZ" ...>
<statements>
	<select id="GetMany" resultMap="ABC.FooResult" parameterClass="map">

I get an exception complaining that resultMap XYZ.ABC.FooResult is not defined. ABC.FooResult is defined in a seperate xml file. In my SqlMap.config file, the xml file containing ABC.FooResult appears before the XYZ resultmap file:

<sqlMaps>
 <sqlMap resource="ABC.xml" />
 <sqlMap resource="XYZ.xml" />
</sqlMaps>

Java people in the #ibatis chatroom (Brandon and Larry) said that to reference a external result map, you needed to do so before the id tag:

<sqlMap namespace="XYZ" ...>
<statements>
	<select resultMap="ABC.FooResult" id="GetMany" parameterClass="map">

That didn't work in IBatisNet.

I also tried creating a local resultmap that extended an external resultmap:

<sqlMap namespace="XYZ" ...>
<resultMaps>
	<resultMap id="FooResult" extends="ABC.FooResult" />			
</resultMaps>
<statements>
	<select id="GetMany" resultMap="FooResult" parameterClass="map">

I received an exception saying something about ABC.FooResult not being found.




-- 
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


Re: [jira] Created: (IBATISNET-45) Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true

Posted by Gilles Bayon <ib...@gmail.com>.
Have you specify 
<setting useStatementNamespaces="true"/> ?

As I remenber, local resultmap cannot extended an external resultmap.

Re: [jira] Created: (IBATISNET-45) Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true

Posted by Gilles Bayon <ib...@gmail.com>.
>Java people in the #ibatis chatroom (Brandon and Larry) said that to
reference a >external result map, you needed to do so before the id
tag:

By the way, in .NET version the order of attribute don't care.

[jira] Closed: (IBATISNET-45) Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true

Posted by "Gilles Bayon (JIRA)" <ib...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/IBATISNET-45?page=all ]
     
Gilles Bayon closed IBATISNET-45:
---------------------------------

     Resolution: Fixed
    Fix Version: DataMapper 1.2

In SVN, Unit test TestJIRA45

> Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true
> -----------------------------------------------------------------------------------------------------
>
>          Key: IBATISNET-45
>          URL: http://issues.apache.org/jira/browse/IBATISNET-45
>      Project: iBatis for .NET
>         Type: Bug
>  Environment: DataMapper: 1.1.458.0
>     Reporter: Ron Grabowski
>     Assignee: Gilles Bayon
>     Priority: Minor
>      Fix For: DataMapper 1.2

>
> If I try to access a result map in a different namespace using this syntax:
> <sqlMap namespace="XYZ" ...>
> <statements>
> 	<select id="GetMany" resultMap="ABC.FooResult" parameterClass="map">
> I get an exception complaining that resultMap XYZ.ABC.FooResult is not defined. ABC.FooResult is defined in a seperate xml file. In my SqlMap.config file, the xml file containing ABC.FooResult appears before the XYZ resultmap file:
> <sqlMaps>
>  <sqlMap resource="ABC.xml" />
>  <sqlMap resource="XYZ.xml" />
> </sqlMaps>
> Java people in the #ibatis chatroom (Brandon and Larry) said that to reference a external result map, you needed to do so before the id tag:
> <sqlMap namespace="XYZ" ...>
> <statements>
> 	<select resultMap="ABC.FooResult" id="GetMany" parameterClass="map">
> That didn't work in IBatisNet.
> I also tried creating a local resultmap that extended an external resultmap:
> <sqlMap namespace="XYZ" ...>
> <resultMaps>
> 	<resultMap id="FooResult" extends="ABC.FooResult" />			
> </resultMaps>
> <statements>
> 	<select id="GetMany" resultMap="FooResult" parameterClass="map">
> I received an exception saying something about ABC.FooResult not being found.

-- 
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] Closed: (IBATISNET-45) Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true

Posted by "Roberto Rabe (JIRA)" <ib...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/IBATISNET-45?page=all ]
     
Roberto Rabe closed IBATISNET-45:
---------------------------------


> Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true
> -----------------------------------------------------------------------------------------------------
>
>          Key: IBATISNET-45
>          URL: http://issues.apache.org/jira/browse/IBATISNET-45
>      Project: iBatis for .NET
>         Type: Bug
>  Environment: DataMapper: 1.1.458.0
>     Reporter: Ron Grabowski
>     Assignee: Gilles Bayon
>     Priority: Minor
>      Fix For: DataMapper 1.2

>
> If I try to access a result map in a different namespace using this syntax:
> <sqlMap namespace="XYZ" ...>
> <statements>
> 	<select id="GetMany" resultMap="ABC.FooResult" parameterClass="map">
> I get an exception complaining that resultMap XYZ.ABC.FooResult is not defined. ABC.FooResult is defined in a seperate xml file. In my SqlMap.config file, the xml file containing ABC.FooResult appears before the XYZ resultmap file:
> <sqlMaps>
>  <sqlMap resource="ABC.xml" />
>  <sqlMap resource="XYZ.xml" />
> </sqlMaps>
> Java people in the #ibatis chatroom (Brandon and Larry) said that to reference a external result map, you needed to do so before the id tag:
> <sqlMap namespace="XYZ" ...>
> <statements>
> 	<select resultMap="ABC.FooResult" id="GetMany" parameterClass="map">
> That didn't work in IBatisNet.
> I also tried creating a local resultmap that extended an external resultmap:
> <sqlMap namespace="XYZ" ...>
> <resultMaps>
> 	<resultMap id="FooResult" extends="ABC.FooResult" />			
> </resultMaps>
> <statements>
> 	<select id="GetMany" resultMap="FooResult" parameterClass="map">
> I received an exception saying something about ABC.FooResult not being found.

-- 
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] Reopened: (IBATISNET-45) Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true

Posted by "Roberto Rabe (JIRA)" <ib...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/IBATISNET-45?page=all ]
     
Roberto Rabe reopened IBATISNET-45:
-----------------------------------


(Visible to ibatis-developers)


> Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true
> -----------------------------------------------------------------------------------------------------
>
>          Key: IBATISNET-45
>          URL: http://issues.apache.org/jira/browse/IBATISNET-45
>      Project: iBatis for .NET
>         Type: Bug
>  Environment: DataMapper: 1.1.458.0
>     Reporter: Ron Grabowski
>     Assignee: Gilles Bayon
>     Priority: Minor
>      Fix For: DataMapper 1.2

>
> If I try to access a result map in a different namespace using this syntax:
> <sqlMap namespace="XYZ" ...>
> <statements>
> 	<select id="GetMany" resultMap="ABC.FooResult" parameterClass="map">
> I get an exception complaining that resultMap XYZ.ABC.FooResult is not defined. ABC.FooResult is defined in a seperate xml file. In my SqlMap.config file, the xml file containing ABC.FooResult appears before the XYZ resultmap file:
> <sqlMaps>
>  <sqlMap resource="ABC.xml" />
>  <sqlMap resource="XYZ.xml" />
> </sqlMaps>
> Java people in the #ibatis chatroom (Brandon and Larry) said that to reference a external result map, you needed to do so before the id tag:
> <sqlMap namespace="XYZ" ...>
> <statements>
> 	<select resultMap="ABC.FooResult" id="GetMany" parameterClass="map">
> That didn't work in IBatisNet.
> I also tried creating a local resultmap that extended an external resultmap:
> <sqlMap namespace="XYZ" ...>
> <resultMaps>
> 	<resultMap id="FooResult" extends="ABC.FooResult" />			
> </resultMaps>
> <statements>
> 	<select id="GetMany" resultMap="FooResult" parameterClass="map">
> I received an exception saying something about ABC.FooResult not being found.

-- 
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] Resolved: (IBATISNET-45) Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true

Posted by "Roberto Rabe (JIRA)" <ib...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/IBATISNET-45?page=all ]
     
Roberto Rabe resolved IBATISNET-45:
-----------------------------------

    Resolution: Fixed

(Visible to ibatis-developers)


> Unable to reference result maps defined in other xml files when useStatementNamespaces is set to true
> -----------------------------------------------------------------------------------------------------
>
>          Key: IBATISNET-45
>          URL: http://issues.apache.org/jira/browse/IBATISNET-45
>      Project: iBatis for .NET
>         Type: Bug
>  Environment: DataMapper: 1.1.458.0
>     Reporter: Ron Grabowski
>     Assignee: Gilles Bayon
>     Priority: Minor
>      Fix For: DataMapper 1.2

>
> If I try to access a result map in a different namespace using this syntax:
> <sqlMap namespace="XYZ" ...>
> <statements>
> 	<select id="GetMany" resultMap="ABC.FooResult" parameterClass="map">
> I get an exception complaining that resultMap XYZ.ABC.FooResult is not defined. ABC.FooResult is defined in a seperate xml file. In my SqlMap.config file, the xml file containing ABC.FooResult appears before the XYZ resultmap file:
> <sqlMaps>
>  <sqlMap resource="ABC.xml" />
>  <sqlMap resource="XYZ.xml" />
> </sqlMaps>
> Java people in the #ibatis chatroom (Brandon and Larry) said that to reference a external result map, you needed to do so before the id tag:
> <sqlMap namespace="XYZ" ...>
> <statements>
> 	<select resultMap="ABC.FooResult" id="GetMany" parameterClass="map">
> That didn't work in IBatisNet.
> I also tried creating a local resultmap that extended an external resultmap:
> <sqlMap namespace="XYZ" ...>
> <resultMaps>
> 	<resultMap id="FooResult" extends="ABC.FooResult" />			
> </resultMaps>
> <statements>
> 	<select id="GetMany" resultMap="FooResult" parameterClass="map">
> I received an exception saying something about ABC.FooResult not being found.

-- 
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