From: Holger B. (JIRA) <no...@at...> - 2006-01-25 01:12:17
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-708?pag= e=3Dcomments#action_21774 ]=20 Holger Bartnick commented on HHH-708: ------------------------------------- it doesn=C2=B4t work in HHH 3.11 anymore The InExpression produces a statement like [where (key, station) in ((?,?),= (?,?)...)] indeed. but the parameter binding is wrong: instead of binding first key to parameter 1 and first station to parameter = 2 it binds first key to parameter 1 and first KEY to parameter 2 etc. at the half of the parameterlist it changes to first station etc. thought it was fixed in 3.1 beta?!? > Restrictions.in could not be used properly on composite-ids > ----------------------------------------------------------- > > Key: HHH-708 > URL: http://opensource.atlassian.com/projects/hibernate/browse/H= HH-708 > Project: Hibernate3 > Type: Bug > Components: core > Versions: 3.0.5 > Environment: Oracle 9i, org.hibernate.criterion.InExpression > Reporter: Holger Bartnick > Fix For: 3.1 beta 1 > > > Restrictions.in could not be used properly on composite-ids > for a composite-id with the attributes key and station > the resulting sql is like:=20 > [where key in (?,?...) and station in (?,?...)] > it should result in an sql like:=20 > [where (key, station) in ((?,?),(?,?)...)] > otherwise the result would be a scalar product=20 > example: > key station > 1 1 > 2 1 > 2 2 > 3 2 > [where key in (1,2,3) and station in (1,2)] > would return all values > [where (key, station) in ((1,1),(2,1),(3,2))] > would omit the record (2,2) --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators= .jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |