Invalid index 0 for this DB2ParameterCollection with Count=0.
Description
All of my database calls now are broken in 3.2. I have traced it down the addition of the call "RemoveUnusedCommandParameters". I am using DB2 zOS v9. I have verified this to be a problem with both the IBM.DB2 provider and the ODBC driver using DB2Dialect. What I don't know is if it is because of an error in the NHibernate.DB2Driver or what. The parameters show up in the sql as "?" but in the parememter collection they show up as p1, p2, p3 ... so when RemoveUnusedCommandParameters is called it removes the parameters.
Thanks for confirming the issue is resolved. FYI: There is a batch file called "ShowBuildMenu.bat" that creates the AssemblyInfo.cs files for you (option A).
David Logan
November 15, 2011 at 5:41 PM
Yes this problem seems to be solved. the version I tested was nhibernate-nhibernate-core-3.2.0GA-98-g08aeab4.zip. A note when I pulled the zip file down the NHibernate and IESI.Collections projects did not come with their respective AssemblyInfo.cs file. I had to copy them from the 3.2.0GA source.
David Logan
November 15, 2011 at 5:04 PM
Yes it looks like it might be. I must have missed that one when I reported the problem. I will download the latest source and try it. I'll update the issue when I do.
Richard Brown
November 15, 2011 at 4:45 PM
Is this a duplicate of NH-2893?
David, are you able to check if this is still a problem in the latest version?
All of my database calls now are broken in 3.2. I have traced it down the addition of the call "RemoveUnusedCommandParameters". I am using DB2 zOS v9. I have verified this to be a problem with both the IBM.DB2 provider and the ODBC driver using DB2Dialect. What I don't know is if it is because of an error in the NHibernate.DB2Driver or what. The parameters show up in the sql as "?" but in the parememter collection they show up as p1, p2, p3 ... so when RemoveUnusedCommandParameters is called it removes the parameters.
Please let me know if you need anything else.
dbl