[
https://issues.apache.org/jira/browse/TORQUE-247?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Thomas Fox resolved TORQUE-247.
-------------------------------
Resolution: Fixed
> Select using a SimpleKey containing a null value does not work
> --------------------------------------------------------------
>
> Key: TORQUE-247
> URL: https://issues.apache.org/jira/browse/TORQUE-247
> Project: Torque
> Issue Type: Bug
> Components: Runtime
> Affects Versions: 4.0-beta1
> Reporter: Thomas Fox
> Assignee: Thomas Fox
> Fix For: 4.0-beta2
>
>
> The code
> SimpleKey keyToSelect = SimpleKey.keyFor((Integer) null);
> Criteria criteria = new Criteria()
> .where(BookPeer.AUTHOR_ID, keyToSelect);
> List<Book> books = BookPeer.doSelect(criteria);
> throws a NullPointerException:
> java.lang.NullPointerException
> at
> org.apache.torque.util.BasePeerImpl.setPreparedStatementReplacements(BasePeerImpl.java:2246)
> at org.apache.torque.util.BasePeerImpl.doSelect(BasePeerImpl.java:1525)
> at org.apache.torque.util.BasePeerImpl.doSelect(BasePeerImpl.java:1152)
> at org.apache.torque.util.BasePeerImpl.doSelect(BasePeerImpl.java:961)
> at
> org.apache.torque.test.peer.base.BaseBookPeer.doSelect(BaseBookPeer.java:305)
> ....
> The problem is that the NullValueBuilder does not check for ObjectKeys
> containing Null
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]