Wrox Home  
Search P2P Archive for: Go

  Return to Index  

pro_jsp thread: How can i commit when using Oracle DB ?


Message #1 by "Maryam Alowais" <alowaism@h...> on Thu, 10 May 2001 05:41:28
The JDBC connection is always set to auto commit after
every statement execute/update, unless you explicitly
ask it not to.

But as pointed out, the explicit commit to the
connection will not hurt either.

ciao 



--- indra budiantho <ibudiantho@y...> wrote:
> try this after u update...
>     conn.commit();
> where conn = the connection..
> --- Maryam Alowais <alowaism@h...> wrote:
> >  Hi,i may use update or insert but how can i make
> > sure is every thing is saved after 
> > the user finish ?
> > and whate is wrong with this statment ?
> > 
> > rowseffected =stmt1.executeUpdate("UPDATE SECTION
> > SET ENROL="+
> >                                  "'"
> > +rs.getInt("ENROL")+1  +"')WHERE    
> > CS_NUM='"+Integer.parseInt(cnum1)+"'"+"AND SEC_NUM
> > ='"+Integer.parseInt(secnum1)
> > +"'");
>

  Return to Index