Javier,

it may be that the dbExpress interface is still lagging behind MySQL
development.

If I recall right, people have complained loudly in Borland newsgroups that
dbExpress created a new connection for each SQL query it issues to MySQL.
That makes the use of transactions impossible with it.

If this has not been fixed in the latest version of dbExpress, it would be
good if you would write to Borland people about this, or to the Borland
newsgroups.

Regards,

Heikki
Innobase Oy

----- Original Message -----
From: "Javier Diaz" <[EMAIL PROTECTED]>
Newsgroups: mailing.database.mysql
Sent: Monday, September 02, 2002 3:06 PM
Subject: Inno DB Question


> Hi all,
>
> I'm using MySQL 4.0.2 alpha-max with Inno DB and Borland Builder 6.0 to
> connect to MySQL. I'm trying to use the new dbExpress component for
Borland
> to connect to MySQL using the libmysql.dll
>
> I have been making some tests with transactions using the dbExpress
> components and the normal ODBC but I can't get the ROLLBACK function to
> work.
> Here are some examples:
>
> using dbExpress
>
> TSQLConnection Q;
> Q= new TSQLQuery(Application);
> Q->SQLConnection=SQLConnection1;
>
> /* I test with and without BEGIN
> Q->SQL->Clear();
> Q->SQL->Add("BEGIN");
> Q->ExecSQL();
> */
>
> Q->SQL->Clear();
> Q->SQL->Add("SET AUTOCOMMIT=0");
> Q->ExecSQL();
>
> Q->SQL->Clear();
> Q->SQL->Add("INSERT INTO regn_info VALUES('t1','test1')");
> Q->ExecSQL();
>
>
> Q->SQL->Clear();
> Q->SQL->Add("INSERT INTO regn_info VALUES('t2','test2')");
> Q->ExecSQL();
>
> Q->SQL->Clear();
> Q->SQL->Add("ROLLBACK");
> Q->ExecSQL();
>
> //----------------------------------------------------------
> Using ODBC
>
>
> TQuery *Q_ODBC;
> Q_ODBC= new TQuery(Application);
> Q_ODBC->DatabaseName="salsadb";
>
> /*
> Q->SQL->Clear();
> Q->SQL->Add("BEGIN");
> Q->ExecSQL();
> */
>
> Q_ODBC->SQL->Clear();
> Q_ODBC->SQL->Add("SET AUTOCOMMIT=0");
> Q_ODBC->ExecSQL();
>
> Q_ODBC->SQL->Clear();
> Q_ODBC->SQL->Add("INSERT INTO regn_info VALUES('t1','test1')");
>
> Q_ODBC->ExecSQL();
>
>
> Q_ODBC->SQL->Clear();
> Q_ODBC->SQL->Add("INSERT INTO regn_info VALUES('t2','test2')");
> Q_ODBC->ExecSQL();
>
> Q_ODBC->SQL->Clear();
> Q_ODBC->SQL->Add("ROLLBACK");
> Q_ODBC->ExecSQL();
>
> In both cases the ROLLBACK dosen't work and I get the inserted values in
the
> table.
>
> Any idea what can be happening?
>
> Thanks a lot
>
> Javier Diaz
>
>
>
> ------------------------------
>
> This e-mail is intended for the named addressee only.  It may contain
confidential and/or privileged information.  If you have received this
message in error, please let us know and then delete this message from your
system.  You should not copy the message, use it for any purpose or disclose
its contents to anyone.
>
>
> ________________________________________________________________________
> This e-mail has been scanned for all viruses by Star Internet. The
> service is powered by MessageLabs. For more information on a proactive
> anti-virus service working around the clock, around the globe, visit:
> http://www.star.net.uk
> ________________________________________________________________________
>
> ---------------------------------------------------------------------
> Before posting, please check:
>    http://www.mysql.com/manual.php   (the manual)
>    http://lists.mysql.com/           (the list archive)
>
> To request this thread, e-mail <[EMAIL PROTECTED]>
> To unsubscribe, e-mail
<[EMAIL PROTECTED]>
> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
>



---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to