ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher.Mathru...@sybase.com
Subject RE: Multiple ResultSet's
Date Mon, 18 Sep 2006 06:59:14 GMT
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META boundary="----=_Part_125709_2679610.1158432534597" alternative; multipart 
Content-Type:>
<META http-equiv=Content-Type content="text/html; charset=us-ascii" 
Content-Type: ------="_Part_125709_2679610.1158432534597" inline 
Content-Disposition: html; text 7bit Content-Transfer-Encoding:>
<META content="MSHTML 6.00.2900.2963" name=GENERATOR></HEAD>
<BODY>
<DIV dir=ltr align=left><SPAN class=468355006-18092006><FONT color=#0000ff

size=2>That might work. Truly the easy solution to the problem is to simply set 
IGNORE_DONE_IN_PROC=true. There is also a global setting on the database that I 
cold set that would basically set IGNORE_DONE_IN_PROC=true on a global level. 
The problem there is that I have no idea how many groups and applications I 
would impact with such a change. (Not recommended)</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=468355006-18092006><FONT color=#0000ff

size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=468355006-18092006><FONT color=#0000ff

size=2>The bottom line here is that bad programming practices have been 
implemented and never reviewed/revisited! Setting the property on the JDBC data 
source is an easy solution. The only reason that I asked the question in the 
first place is that I managed to find a bug in the JConnect JDBC driver that is 
not scheduled to be fixed any time soon. Setting this property causes an 
exception to be raised when I run in Jta. (Although I am told it is not Jta 
related) My work-around for now it to use an older version of the driver that 
does not have the problem. </FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=468355006-18092006><FONT color=#0000ff

size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=468355006-18092006><FONT color=#0000ff

size=2>I don't know how many database vendors have this type of functionality. I 
know that Oracle does not because I never saw this type of behavior on my last 
project. Nor did I see this on DB2. It's been a while since I worked with MS SQL 
Server, but I don't recall seeing anything like this. I don't want you to 
implement anything that is vendor specific. That would simply be absurd and I 
could not see the need for it no matter what.</FONT></SPAN></DIV><BR>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> "Clinton Begin" 
&lt;clinton.begin@gmail.com&gt; [mailto:"Clinton Begin" 
&lt;clinton.begin@gmail.com&gt;] <BR><B>Sent:</B> Saturday, September
16, 2006 
11:49 AM<BR><B>To:</B> user-java@ibatis.apache.org<BR><B>Subject:</B>
Re: 
Multiple ResultSet's<BR></FONT><BR></DIV>
<DIV></DIV>Yeesh.&nbsp; :-)<BR><BR>Unfortunately not at this time.&nbsp;
But I 
wonder if we could add support for a connection lifecycle event handler.&nbsp; 
So that when a connection is retrieved from the datasouce, you have an 
opportunity to manipulate it and set such properties -- without having to resort 
to user supplied connections all the time.&nbsp; <BR><BR>Would that 
work?<BR><BR>Thoughts?<BR><BR>Clinton<BR><BR>
<DIV><SPAN class=gmail_quote>On 9/13/06, <B class=gmail_sendername><A

href="mailto:Christopher.Mathrusse@sybase.com">Christopher.Mathrusse@sybase.com</A>

</B>&lt;<A 
href="mailto:Christopher.Mathrusse@sybase.com">Christopher.Mathrusse@sybase.com</A>&gt;

wrote:</SPAN>
<BLOCKQUOTE class=gmail_quote 
style="PADDING-LEFT: 1ex; MARGIN: 0pt 0pt 0pt 0.8ex; BORDER-LEFT: rgb(204,204,204) 1px solid">
  <DIV>
  <DIV>
  <DIV><FONT color=#0000ff size=2><SPAN>I have a problem with the way that

  Sybase ASE works with stored procs and triggers. I'm working with a legacy 
  database that is very poorly designed. All work&nbsp;is performed using procs 
  and triggers and it's almost impossible to trace it all down. The problem I'm 
  having is that ASE build results sets, know as done-in-proc result sets, for 
  each proc&nbsp;that is executed. As most of the triggers on this databases 
  tables call sp's there can be a large&nbsp;number of done-in-proc 
  resultSets.&nbsp;</SPAN></FONT></DIV>
  <DIV><FONT color=#0000ff size=2><SPAN></SPAN></FONT>&nbsp;</DIV>
  <DIV><FONT color=#0000ff size=2><SPAN>The problem manifests itself when
an 
  error is raised by a proc.&nbsp;The execution of the SQL Statement returns but 
  there can be multiple result sets and only the last one contains the error. 
  The JConnect JDBC driver has a parameter that can be set, 
  (IGNORE_DONE_IN_PROC) that tells the driver to ignore the done-in-proc result 
  sets and only look at the last one. (NO brainner right?) </SPAN></FONT></DIV>
  <DIV><FONT color=#0000ff size=2><SPAN></SPAN></FONT>&nbsp;</DIV>
  <DIV><FONT color=#0000ff size=2><SPAN>My question is, is there a way to
tell 
  iBatis to only look at the last result set so I don't need to set the 
  parameter on the connection? I know support for multiple result sets was 
  recently added but I don't think that it was intended to be used for this type 
  of situation.</SPAN></FONT></DIV>
  <DIV><FONT color=#0000ff size=2><SPAN></SPAN></FONT>&nbsp;</DIV>
  <DIV><FONT color=#0000ff 
  size=2><SPAN>Thanks....</SPAN></FONT></DIV></DIV></DIV></BLOCKQUOTE></DIV><BR></BODY></HTML>


Mime
View raw message