OT: (Though I really do need a solution to this) To retrieve RAISERROR messages from Sybase we used a feature that is built into the sybase driver. You can set a message handler on the connection when it's created. I used a feature of Websphere (the application container that will be hosting my applications) called the DataStoreHelper in order to intercept the creation of the connection.
To limit the maximum number of rows returned (a feature that we had previously done by using our own custom driver) was to use the Sybase connection property 'SQLINISTRING' to pass a 'set rowcount 2005' to sybase when the connection was created. After extensive testing we saw that while SPs could override the rowcount (which is fine) that override was scoped to the life of the SP and no longer. Lambert Torres wrote: > > Can you share what the workarounds were? > > OT: > So far we have gotten > around issues such as not having a handle on the connection to retrieve > RAISERROR messages from a stored procedure as well as limiting the number > of > results. > > > thanks, > Lambert > > Lambert Torres > NBA Information Technology > Web Technology Group > 100 Plaza Drive > Secaucus, NJ 07094 > Ph : (201) 974-6785 > Fax: (201) 974-6001 > > > > > BenBaril > <[EMAIL PROTECTED] > bn.ca> To > user-java@ibatis.apache.org > 05/18/2007 06:43 cc > PM > Subject > Retrieve stored proc return code > Please respond to > [EMAIL PROTECTED] > apache.org > > > > > > > > > Hi All, > > I know this issue has come up before, but I'm curious if there is a > solution. I am in the process of evaluating iBatis (and we have pretty > much > decided on it) as the sql mapper for our IT-Revitalization project. We > have > over 1000 Stored Procedures in a Sybase database. So far we have gotten > around issues such as not having a handle on the connection to retrieve > RAISERROR messages from a stored procedure as well as limiting the number > of > results. > > Our problem right now is that we cannot retrieve the return code from an > SP. > We rely heavily on return codes to determine why a stored procedure may > have > failed, and we need these codes to propagate back up the Java stack so we > can have a handle on them. > > Is there a way to do this using iBatis right now? > > Thank you, > Benjamin Baril > -- > View this message in context: > http://www.nabble.com/Retrieve-stored-proc-return-code-tf3780537.html#a10691634 > > Sent from the iBATIS - User - Java mailing list archive at Nabble.com. > > > > > -- View this message in context: http://www.nabble.com/Retrieve-stored-proc-return-code-tf3780537.html#a10694633 Sent from the iBATIS - User - Java mailing list archive at Nabble.com.