You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ibatis.apache.org by ro...@apache.org on 2005/05/06 07:17:09 UTC
svn commit: r168523 - in
/incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP:
Account.xml Category.xml LineItem.xml Order.xml Other.xml
Author: roberto
Date: Thu May 5 22:17:09 2005
New Revision: 168523
URL: http://svn.apache.org/viewcvs?rev=168523&view=rev
Log:
~Updated C# DataMapper NUnit Oracle ODP SqlMaps for test results/exceptions with ODP.NET 10g
Modified:
incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Account.xml
incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Category.xml
incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/LineItem.xml
incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Order.xml
incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Other.xml
Modified: incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Account.xml
URL: http://svn.apache.org/viewcvs/incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Account.xml?rev=168523&r1=168522&r2=168523&view=diff
==============================================================================
--- incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Account.xml (original)
+++ incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Account.xml Thu May 5 22:17:09 2005
@@ -422,29 +422,6 @@
(#Id:Int32#, #FirstName#, #LastName#, #EmailAddress#)
</insert>
-
- <!--
- StatementTest.TestUpdateWithInlineParameters :
- Throws Oracle.DataAccess.Client.OracleException :
- ORA-01407: cannot update ("IBATISNET"."ACCOUNTS"."ACCOUNT_FIRSTNAME") to NULL
-
- at Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object src, String procedure)
- at Oracle.DataAccess.Client.OracleException.HandleError(Int32 errCode, OracleConnection conn, String procedure, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object src)
- at Oracle.DataAccess.Client.OracleCommand.ExecuteNonQuery()
- at IBatisNet.DataMapper.MappedStatements.MappedStatement.ExecuteUpdate(IDalSession session, Object parameterObject) in c:\projects\ibatis\svn\source\ibatisnet.datamapper\mappedstatements\mappedstatement.cs:line 770
- at IBatisNet.DataMapper.SqlMapper.Update(String statementName, Object parameterObject) in c:\projects\ibatis\svn\source\ibatisnet.datamapper\sqlmapper.cs:line 834
- at IBatisNet.Test.NUnit.SqlMapTests.StatementTest.TestUpdateWithInlineParameters() in c:\projects\ibatis\svn\source\ibatisnet.test\nunit\sqlmaptests\statementtest.cs:line 924
-
- Upon inspection, CommandText looks ok and Parameter order/types/values look ok:
- update Accounts set Account_FirstName = :FirstName , Account_LastName = :LastName , Account_Email = :EmailAddress where Account_ID = :Id
-
- update Accounts set
- Account_FirstName = #FirstName#,
- Account_LastName = #LastName#,
- Account_Email = #EmailAddress:VarChar2:no_email@provided.com#
- where
- Account_ID = #Id:Int32#
- -->
<!-- Inline Parameters -->
<update id="UpdateAccountViaInlineParameters"
parameterMap="update-params">
Modified: incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Category.xml
URL: http://svn.apache.org/viewcvs/incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Category.xml?rev=168523&r1=168522&r2=168523&view=diff
==============================================================================
--- incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Category.xml (original)
+++ incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Category.xml Thu May 5 22:17:09 2005
@@ -67,13 +67,6 @@
(?,?,?)
</insert>
- <!--
- Throws OracleException Illegal variable name/number
-
- WorkAround:
- Use a specific parameterMap for the UPDATE
- or use a parameterClass instead of an extended parameterMap
- -->
<update id="UpdateCategoryViaParameterMap" parameterMap="UpdateParam">
update Categories set
Category_Id = ?,
Modified: incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/LineItem.xml
URL: http://svn.apache.org/viewcvs/incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/LineItem.xml?rev=168523&r1=168522&r2=168523&view=diff
==============================================================================
--- incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/LineItem.xml (original)
+++ incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/LineItem.xml Thu May 5 22:17:09 2005
@@ -77,18 +77,6 @@
and LineItem_ID = #LineItem_ID:Int32#
</statement>
- <!--
- ResultMapTest.TestByteArrayMapping :
-
- at NUnit.Framework.Assert.Fail(String message, Object[] args)
- at NUnit.Framework.Assert.IsTrue(Boolean condition, String message, Object[] args)
- at NUnit.Framework.Assert.IsNotNull(Object anObject, String message, Object[] args)
- at NUnit.Framework.Assert.IsNotNull(Object anObject)
- at IBatisNet.Test.NUnit.SqlMapTests.ResultMapTest.TestByteArrayMapping() in C:\projects\ibatis\svn\Source\IBatisNet.Test\NUnit\SqlMapTests\ResultMapTest.cs:line 354
-
- InsertLineItemWithPicture did not insert the byte array
- (database record column is null when inspected)
- -->
<statement id="GetSpecificLineItemWithPicture"
parameterClass="Hashtable"
resultClass="LineItem">
@@ -140,14 +128,6 @@
(?, ?, ?, ?, ?)
</statement>
- <!--
- ResultMapTest.TestByteArrayMapping :
- No exceptions when using Raw dbType
- but picture data is not really inserted
-
- InsertLineItemWithPicture did not insert the byte array
- (database record column is null when inspected)
- -->
<statement id="InsertLineItemWithPicture"
parameterMap="insert-params-picture" >
insert into LineItems
Modified: incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Order.xml
URL: http://svn.apache.org/viewcvs/incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Order.xml?rev=168523&r1=168522&r2=168523&view=diff
==============================================================================
--- incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Order.xml (original)
+++ incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Order.xml Thu May 5 22:17:09 2005
@@ -278,6 +278,25 @@
(?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
</statement>
+ <!--
+ Throws Oracle.DataAccess.Types.OracleTypeException :
+ numeric precision specifier is out of range (1 to 38)
+
+ at Oracle.DataAccess.Client.OracleCommand.ExecuteReader(Boolean requery, Boolean fillRequest, CommandBehavior behavior)
+ at Oracle.DataAccess.Client.OracleCommand.System.Data.IDbCommand.ExecuteReader()
+ at IBatisNet.DataMapper.MappedStatements.MappedStatement.RunQueryForObject(RequestScope request, IDalSession session, Object parameterObject, Object resultObject) in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper\MappedStatements\MappedStatement.cs:line 571
+ at IBatisNet.DataMapper.MappedStatements.MappedStatement.ExecuteQueryForObject(IDalSession session, Object parameterObject, Object resultObject) in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper\MappedStatements\MappedStatement.cs:line 517
+ at IBatisNet.DataMapper.MappedStatements.MappedStatement.ExecuteQueryForObject(IDalSession session, Object parameterObject) in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper\MappedStatements\MappedStatement.cs:line 498
+ at IBatisNet.DataMapper.MappedStatements.MappedStatement.ExecutePostSelect(IDalSession session, RequestScope request) in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper\MappedStatements\MappedStatement.cs:line 1027
+ at IBatisNet.DataMapper.MappedStatements.MappedStatement.RunQueryForObject(RequestScope request, IDalSession session, Object parameterObject, Object resultObject) in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper\MappedStatements\MappedStatement.cs:line 579
+ at IBatisNet.DataMapper.MappedStatements.MappedStatement.ExecuteQueryForObject(IDalSession session, Object parameterObject, Object resultObject) in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper\MappedStatements\MappedStatement.cs:line 517
+ at IBatisNet.DataMapper.MappedStatements.MappedStatement.ExecuteQueryForObject(IDalSession session, Object parameterObject) in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper\MappedStatements\MappedStatement.cs:line 498
+ at IBatisNet.DataMapper.SqlMapper.QueryForObject(String statementName, Object parameterObject) in c:\projects\ibatis\asf\trunk\cs\mapper\ibatisnet.datamapper\sqlmapper.cs:line 508
+ at IBatisNet.DataMapper.Test.NUnit.SqlMapTests.ResultMapTest.TestDynamiqueCompositeKeyMapping() in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper.Test\NUnit\SqlMapTests\ResultMapTest.cs:line 276
+
+ PostSelect ApplyParameterMap is not grabbing sqlParameter.DbType (Int32)
+ and setting new parameter DbType.
+ -->
<select id="GetOrderWithDynFavouriteLineItem"
parameterClass="Integer"
resultMap="order-with-dyn-favourite-line-item">
Modified: incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Other.xml
URL: http://svn.apache.org/viewcvs/incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Other.xml?rev=168523&r1=168522&r2=168523&view=diff
==============================================================================
--- incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Other.xml (original)
+++ incubator/ibatis/trunk/cs/mapper/IBatisNet.DataMapper.Test/Maps/Oracle/ODP/Other.xml Thu May 5 22:17:09 2005
@@ -74,6 +74,18 @@
Where Other_Bit = #Bool#
</statement>
+
+ <!--
+ Throws System.ArgumentException :
+ Value does not fall within the expected range.
+
+ at Oracle.DataAccess.Client.OracleParameter.set_Value(Object value)
+ at IBatisNet.DataMapper.Commands.DefaultPreparedCommand.ApplyParameterMap(IDalSession session, IDbCommand command, RequestScope request, IStatement statement, Object parameterObject) in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper\Commands\DefaultPreparedCommand.cs:line 172
+ at IBatisNet.DataMapper.Commands.DefaultPreparedCommand.Create(RequestScope request, IDalSession session, IStatement statement, Object parameterObject) in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper\Commands\DefaultPreparedCommand.cs:line 80
+ at IBatisNet.DataMapper.MappedStatements.MappedStatement.ExecuteInsert(IDalSession session, Object parameterObject) in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper\MappedStatements\MappedStatement.cs:line 844
+ at IBatisNet.DataMapper.SqlMapper.Insert(String statementName, Object parameterObject) in c:\projects\ibatis\asf\trunk\cs\mapper\ibatisnet.datamapper\sqlmapper.cs:line 904
+ at IBatisNet.DataMapper.Test.NUnit.SqlMapTests.StatementTest.TestJIRA42() in C:\projects\ibatis\asf\trunk\cs\mapper\IBatisNet.DataMapper.Test\NUnit\SqlMapTests\StatementTest.cs:line 1073
+ -->
<statement id="InsertBool"
parameterClass="Other">
Insert into Others