dbTalk Databases Forums  

Best way to insert rows from VB to RDB?

comp.databases.rdb comp.databases.rdb


Discuss Best way to insert rows from VB to RDB? in the comp.databases.rdb forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Michael G.
 
Posts: n/a

Default Best way to insert rows from VB to RDB? - 03-09-2006 , 10:23 AM






Hello!

I need to insert rows to RDB table with VB6 program. What is the best
way to do it?
I wrote a VB6 program which inserts rows into RDB table. I use ADO over
Oracle ODBC for RDB. I manage transactions using
ADODB.Connection.BeginTransaction and
ADODB.Connection.CommitTransaction. The rows are inserted by composing
SQL INSERT statement and then calling ADODB.Connection.Execute.with
SQL. It looks like:

ADODB.Connection.BeginTransaction
SQLString = "insert into table values()"
ADODB.Connection.Execute SQLString
ADODB.Connection.CommitTransaction

There is for sure only one instance of VB program which runs.
The RDB table becomes locked. I tried to play with transaction
IsolationLevel of ADO - no results.
The most sad thing is that it worked for 3 days and started to fail
afterward.
What is the problem?
TIA
MIchael


Reply With Quote
  #2  
Old   
noone
 
Posts: n/a

Default Re: Best way to insert rows from VB to RDB? - 03-11-2006 , 09:43 PM






Michael G. wrote:
Quote:
Hello!

I need to insert rows to RDB table with VB6 program. What is the best
way to do it?
I wrote a VB6 program which inserts rows into RDB table. I use ADO over
Oracle ODBC for RDB. I manage transactions using
ADODB.Connection.BeginTransaction and
ADODB.Connection.CommitTransaction. The rows are inserted by composing
SQL INSERT statement and then calling ADODB.Connection.Execute.with
SQL. It looks like:

ADODB.Connection.BeginTransaction
SQLString = "insert into table values()"
ADODB.Connection.Execute SQLString
ADODB.Connection.CommitTransaction

There is for sure only one instance of VB program which runs.
The RDB table becomes locked. I tried to play with transaction
IsolationLevel of ADO - no results.
The most sad thing is that it worked for 3 days and started to fail
afterward.
What is the problem?
TIA
MIchael

are you blocking yourself?

$rmu/sh lock/mode=block

does it have multiple connections?



Reply With Quote
Reply




Thread Tools
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.