problem doing insert into a table when using XAConnection
am 12.09.2006 23:46:54 von Sadhana Jain------_=_NextPart_001_01C6D6B4.F71FE7A0
Content-Type: multipart/alternative;
boundary="----_=_NextPart_002_01C6D6B4.F71FE7A0"
------_=_NextPart_002_01C6D6B4.F71FE7A0
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
Hi,
=20
I am using MySql latest server (5.0.24) and the
mysql-connector-java-5.0.3-bin.jar driver.=20
=20
I am attaching the sample problem I wrote to isolate the bug. When using
the XAConnection
(setting testWithXA=3Dtrue) and doing the insert into the table, the
executeUpdate succeeds and returns 1 but
Nothing gets written to the table.
=20
When using non-XA connection (setting testWithXA=3Dfalse), the entry =
gets
inserted into the table fine.
=20
The output of the program with XA (or non-XA):
=20
URL string is:jdbc:mysql://localhost:3306/test
UserId: root Password: password
XAConnection Successful!
Connection successful!
1 -> uuid:3BADFD00-C692-D46C-193A-E511ED7E9453
2 -> 1158085128
3 -> 0
4 -> 86400000
5 -> 1158085695
num rows written =3D1
=20
Using command line client (when XA):
mysql> select * from SequenceHistory;
Empty set (0.00 sec)
=20
Using command line client (when non XA):
mysql> select * from SequenceHistory;
+-------------------------------------------+--------------- ----+-------
-+------
--------+----------------+-------------------+-------------- --+
| sequenceID | lastMessageNumber | closed
| creat
ionTime | lastAccessTime | inactivityTimeout | expirationTime |
+-------------------------------------------+--------------- ----+-------
-+------
--------+----------------+-------------------+-------------- --+
| uuid:3BADFD00-C692-D46C-193A-E511ED7E9453 | 0 | 0
| 115
8085128 | 1158085695 | 86400000 | 0 |
+-------------------------------------------+--------------- ----+-------
-+------
--------+----------------+-------------------+-------------- --+
1 row in set (0.21 sec)
=20
=20
Can someone please tell me if I am missing some settings when using
XAConnection or this seems like a bug with MySQL?
=20
Thanks very much for any help!
Sadhana
------_=_NextPart_002_01C6D6B4.F71FE7A0
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
xmlns=3D"http://www.w3.org/TR/REC-html40">
charset=3Dus-ascii">
style=3D'font-size:10.0pt;
font-family:Arial'>Hi,
style=3D'font-size:10.0pt;
font-family:Arial'>
style=3D'font-size:10.0pt;
font-family:Arial'>I am using MySql latest server (5.0.24) and the =
mysql-connector-java-5.0.3-bin.jar
driver.
style=3D'font-size:10.0pt;
font-family:Arial'>
style=3D'font-size:10.0pt;
font-family:Arial'>I am attaching the sample problem I wrote to isolate =
the
bug. When using the XAConnection
style=3D'font-size:10.0pt;
font-family:Arial'>(setting testWithXA=3Dtrue) and doing the insert into =
the
table, the executeUpdate succeeds and returns 1 =
but
style=3D'font-size:10.0pt;
font-family:Arial'>Nothing gets written to the =
table.
style=3D'font-size:10.0pt;
font-family:Arial'>
style=3D'font-size:10.0pt;
font-family:Arial'>When using non-XA connection (setting =
testWithXA=3Dfalse), the
entry gets inserted into the table fine.
style=3D'font-size:10.0pt;
font-family:Arial'>
style=3D'font-size:10.0pt;
font-family:Arial'>The output of the program with XA (or =
non-XA):
style=3D'font-size:10.0pt;
font-family:Arial'>
style=3D'font-size:10.0pt;
font-family:Arial'>URL string =
is:jdbc:mysql://localhost:3306/test
style=3D'font-size:10.0pt;
font-family:Arial'>UserId: root Password: =
password
style=3D'font-size:10.0pt;
font-family:Arial'>XAConnection Successful!
style=3D'font-size:10.0pt;
font-family:Arial'>Connection successful!
style=3D'font-size:10.0pt;
font-family:Arial'> 1 -> =
uuid:3BADFD00-C692-D46C-193A-E511ED7E9453
style=3D'font-size:10.0pt;
font-family:Arial'> 2 -> 1158085128
style=3D'font-size:10.0pt;
font-family:Arial'> 3 -> 0
style=3D'font-size:10.0pt;
font-family:Arial'> 4 -> 86400000
style=3D'font-size:10.0pt;
font-family:Arial'> 5 -> 1158085695
style=3D'font-size:10.0pt;
font-family:Arial'>num rows written =3D1
style=3D'font-size:10.0pt;
font-family:Arial'>
style=3D'font-size:10.0pt;
font-family:Arial'>Using command line client (when =
XA):
style=3D'font-size:10.0pt;
font-family:Arial'>mysql> select * from =
SequenceHistory;
style=3D'font-size:10.0pt;
font-family:Arial'>Empty set (0.00 sec)
style=3D'font-size:10.0pt;
font-family:Arial'>
style=3D'font-size:10.0pt;
font-family:Arial'>Using command line client (when non =
XA):
style=3D'font-size:10.0pt;
font-family:Arial'>mysql> select * from =
SequenceHistory;
style=3D'font-size:10.0pt;
font-family:Arial'>+---------------------------------------- ---+---------=
----------+--------+------
style=3D'font-size:10.0pt;
font-family:Arial'>--------+----------------+--------------- ----+--------=
--------+
style=3D'font-size:10.0pt;
font-family:Arial'>|
sequenceID &nb=
sp; &nbs=
p;
| lastMessageNumber | closed | creat
style=3D'font-size:10.0pt;
font-family:Arial'>ionTime | lastAccessTime | inactivityTimeout |
expirationTime |
style=3D'font-size:10.0pt;
font-family:Arial'>+---------------------------------------- ---+---------=
----------+--------+------
style=3D'font-size:10.0pt;
font-family:Arial'>--------+----------------+--------------- ----+--------=
--------+
style=3D'font-size:10.0pt;
font-family:Arial'>| uuid:3BADFD00-C692-D46C-193A-E511ED7E9453 | =
&=
nbsp; 0
| 0 | =
115
style=3D'font-size:10.0pt;
font-family:Arial'>8085128 | 1158085695
| 86400000
| =
0 |
style=3D'font-size:10.0pt;
font-family:Arial'>+---------------------------------------- ---+---------=
----------+--------+------
style=3D'font-size:10.0pt;
font-family:Arial'>--------+----------------+--------------- ----+--------=
--------+
style=3D'font-size:10.0pt;
font-family:Arial'>1 row in set (0.21 sec)
style=3D'font-size:10.0pt;
font-family:Arial'>
style=3D'font-size:10.0pt;
font-family:Arial'>
style=3D'font-size:10.0pt;
font-family:Arial'>Can someone please tell me if I am missing some =
settings
when using XAConnection or this seems like a bug with =
MySQL?
style=3D'font-size:10.0pt;
font-family:Arial'>
style=3D'font-size:10.0pt;
font-family:Arial'>Thanks very much for any =
help!
style=3D'font-size:10.0pt;
font-family:Arial'>Sadhana
------_=_NextPart_002_01C6D6B4.F71FE7A0--
------_=_NextPart_001_01C6D6B4.F71FE7A0
Content-Type: text/plain; charset=us-ascii
--
MySQL Bugs Mailing List
For list archives: http://lists.mysql.com/bugs
To unsubscribe: http://lists.mysql.com/bugs?unsub=gcdmb-bugs@m.gmane.org
------_=_NextPart_001_01C6D6B4.F71FE7A0--