![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hi! I have a problem using XA transaction. I have two database on the same oracle server. If I start two transactions with the same XID, one transaction returns an XA and Oracle error (ORA-24757). The two trasactions are started from two different clients. I'd like to know if there is a workaround about this problem, or if Oracle is able to understand that the XID is related to two different databases also if on the same server. Then, I read on one google group, that Oracle keeps in memory, for a while, the XID of the transaction also if they are ended (committed or rolled-back). Is this true? Is there a way to deny this Oracle behaviour? Thank you! |
#3
| |||
| |||
|
|
sfama wrote: Hi! I have a problem using XA transaction. I have two database on the same oracle server. If I start two transactions with the same XID, one transaction returns an XA and Oracle error (ORA-24757). The two trasactions are started from two different clients. I'd like to know if there is a workaround about this problem, or if Oracle is able to understand that the XID is related to two different databases also if on the same server. Then, I read on one google group, that Oracle keeps in memory, for a while, the XID of the transaction also if they are ended (committed or rolled-back). Is this true? Is there a way to deny this Oracle behaviour? Thank you! Why explicitly state a transaction identifier? Let Oracle handle the transactions for you. It's pretty good at doing that job! Please go through the Oracle Concepts manual (http://tahiti.oracle.com) for your specific version to get a better understanding of how Oracle handles transactions. Thanks, Brian -- ================================================== ================= Brian Peasland dba (AT) nospam (DOT) peasland.net http://www.peasland.net Remove the "nospam." from the email address to email me. "I can give it to you cheap, quick, and good. Now pick two out of the three" - Unknown |
#4
| |||
| |||
|
|
Yes, it could be a good solution, but if it couldn't be possible for me, is there a way to solve this problem or to have a workaroud? |
#5
| |||
| |||
|
|
sfama wrote: Yes, it could be a good solution, but if it couldn't be possible for me, is there a way to solve this problem or to have a workaroud? The workaround is to not state a transaction identifier. Do you have a specific need to do so? If you must state a transaction identifier, why must you do that? If you do not need to, don't as it can cause you problems. Did you read the concepts manual pertaining to transactions? HTH, Brian -- ================================================== ================= Brian Peasland dba (AT) nospam (DOT) peasland.net http://www.peasland.net Remove the "nospam." from the email address to email me. "I can give it to you cheap, quick, and good. Now pick two out of the three" - Unknown |
#6
| |||
| |||
|
|
Yes, cause may happen that one or more clients not developed from me, start trasactions and set XIDs. We'd like to prevent that two clients set the same XID; I made some test and Oracle stops the transaction if one XID has just been used. We tried to set another transaction code: if we receive a request to start a transaction and a XID from the client, we set another trasaction code. This goes well. But if something wrong happens and a transaction was not completed, we lost the transaction code, but we have the XID (I don't know if I'm clear). So we'd like not to use the transaction code and use only th XID, but to avoid to have duplicate XID from different client, or if this happens, that Oracle manages it. About the manual, I'm giving a look at this! Thanks! Brian Peasland ha scritto: sfama wrote: Yes, it could be a good solution, but if it couldn't be possible for me, is there a way to solve this problem or to have a workaroud? The workaround is to not state a transaction identifier. Do you have a specific need to do so? If you must state a transaction identifier, why must you do that? If you do not need to, don't as it can cause you problems. Did you read the concepts manual pertaining to transactions? HTH, Brian -- ================================================== ================= Brian Peasland dba (AT) nospam (DOT) peasland.net http://www.peasland.net Remove the "nospam." from the email address to email me. "I can give it to you cheap, quick, and good. Now pick two out of the three" - Unknown |
#7
| |||
| |||
|
|
Yes, cause may happen that one or more clients not developed from me, start trasactions and set XIDs. We'd like to prevent that two clients set the same XID; I made some test and Oracle stops the transaction if one XID has just been used. We tried to set another transaction code: if we receive a request to start a transaction and a XID from the client, we set another trasaction code. This goes well. But if something wrong happens and a transaction was not completed, we lost the transaction code, but we have the XID (I don't know if I'm clear). So we'd like not to use the transaction code and use only th XID, but to avoid to have duplicate XID from different client, or if this happens, that Oracle manages it. About the manual, I'm giving a look at this! Thanks! Brian Peasland ha scritto: sfama wrote: Yes, it could be a good solution, but if it couldn't be possible for me, is there a way to solve this problem or to have a workaroud? The workaround is to not state a transaction identifier. Do you have a specific need to do so? If you must state a transaction identifier, why must you do that? If you do not need to, don't as it can cause you problems. Did you read the concepts manual pertaining to transactions? HTH, Brian -- ================================================== ================= Brian Peasland dba (AT) nospam (DOT) peasland.net http://www.peasland.net Remove the "nospam." from the email address to email me. "I can give it to you cheap, quick, and good. Now pick two out of the three" - Unknown |
#8
| |||
| |||
|
|
sfama wrote: Yes, it could be a good solution, but if it couldn't be possible for me, is there a way to solve this problem or to have a workaroud? The workaround is to not state a transaction identifier. Do you have a specific need to do so? If you must state a transaction identifier, why must you do that? If you do not need to, don't as it can cause you problems. Did you read the concepts manual pertaining to transactions? HTH, Brian -- ================================================== ================= Brian Peasland dba (AT) nospam (DOT) peasland.net http://www.peasland.net Remove the "nospam." from the email address to email me. "I can give it to you cheap, quick, and good. Now pick two out of the three" - Unknown |
#9
| |||
| |||
|
|
Brian Peasland ha scritto: sfama wrote: The workaround is to not state a transaction identifier. Do you have a specific need to do so? snipped HTH, Brian -- cause may happen that one or more clients not developed from me, start trasactions and set XIDs. |
#10
| |||
| |||
|
|
Yes, cause may happen that one or more clients not developed from me, start trasactions and set XIDs. |
|
We'd like to prevent that two clients set the same XID; I made some test and Oracle stops the transaction if one XID has just been used. |
|
We tried to set another transaction code: if we receive a request to start a transaction and a XID from the client, we set another trasaction code. This goes well. But if something wrong happens and a transaction was not completed, we lost the transaction code, but we have the XID (I don't know if I'm clear). So we'd like not to use the transaction code and use only th XID, but to avoid to have duplicate XID from different client, or if this happens, that Oracle manages it. |
![]() |
| Thread Tools | |
| Display Modes | |
| |