iBatis cache can't handle null values
-------------------------------------
Key: IBATISNET-129
URL: http://issues.apache.org/jira/browse/IBATISNET-129
Project: iBatis for .NET
Type: Bug
Components: DataMapper
Versions: DataMapper 1.2.1
Environment: .NET 2.0
Reporter: Phil Kulak
Here's the relevent source from MappedStatement.cs:
obj = _statement.CacheModel[key];
if (obj == null)
{
obj = RunQueryForObject(request, session, parameterObject,
resultObject);
_statement.CacheModel[key] = obj;
}
Notice that this code assumes that a null value means that the key doesn't
exist when the key could exist and just be mapped to null, as is the case for a
query that returns no result. This causes an "Item has already been added."
exception.
--
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