If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Informix > Transaction using JDBC

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 08-11-03, 09:12
nikhilbhave nikhilbhave is offline
Registered User
 
Join Date: Aug 2003
Location: India
Posts: 4
Post Transaction using JDBC

I am using Informix Dynamic Server 7.3 on UNIX. I am connecting to the DB using JDBC driver. My application requires transaction to be maintained while inserting data. But when I call setAutoCommit(false) a SQLException is thrown saying "Transaction Not Supported".

What is the possible cause of this error? Any settings to be made while installation? I have searched IBM's site for help but couldn't find any.

Can anyone help me out please to find a solution.
Reply With Quote
  #2 (permalink)  
Old 08-12-03, 00:01
lloydnwo lloydnwo is offline
Registered User
 
Join Date: Aug 2003
Location: India
Posts: 262
Re: Transaction using JDBC

Quote:
Originally posted by nikhilbhave
I am using Informix Dynamic Server 7.3 on UNIX. I am connecting to the DB using JDBC driver. My application requires transaction to be maintained while inserting data. But when I call setAutoCommit(false) a SQLException is thrown saying "Transaction Not Supported".

What is the possible cause of this error? Any settings to be made while installation? I have searched IBM's site for help but couldn't find any.

Can anyone help me out please to find a solution.
Hi Nikhil,

First of all check whether you can connect thru ODBC. Create a system DSN & try connecting it. Alternatively you can check whether your database was created with logging i.e. either buffered or Mode Ansi. If your database was created without logging then it won't support transactions. You can also install the informix client sdk 2.81 ver. from the ibm site and check.

Regards,

lloyd
Reply With Quote
  #3 (permalink)  
Old 12-17-03, 15:15
afortu2002 afortu2002 is offline
Registered User
 
Join Date: Dec 2003
Posts: 14
Question Re: Transaction using JDBC

i have the same problem. how can i see if my database was created with logging? i have the informix client sdk, how can i check this?.
thank's!!!!



Quote:
Originally posted by lloydnwo
Hi Nikhil,

First of all check whether you can connect thru ODBC. Create a system DSN & try connecting it. Alternatively you can check whether your database was created with logging i.e. either buffered or Mode Ansi. If your database was created without logging then it won't support transactions. You can also install the informix client sdk 2.81 ver. from the ibm site and check.

Regards,

lloyd
Reply With Quote
  #4 (permalink)  
Old 12-18-03, 00:30
nikhilbhave nikhilbhave is offline
Registered User
 
Join Date: Aug 2003
Location: India
Posts: 4
Found a solution. create database using following:
Create DATABASE <dbname> WITH LOG MODE ANSI

This will solve the problem of setAutoCommit(false) throwing an exception.

Regards,
Nikhil
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On