ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » How to use MQSI db node to insert values into mutiple tbls

Post new topic  Reply to topic
 How to use MQSI db node to insert values into mutiple tbls « View previous topic :: View next topic » 
Author Message
narendra
PostPosted: Fri Jun 07, 2002 7:59 am    Post subject: How to use MQSI db node to insert values into mutiple tbls Reply with quote

Apprentice

Joined: 04 Jun 2002
Posts: 26


I am using the MQSI database node to insert values into mutiple tables in the same database.
I would like to know the best method to make sure that all inserts have to be successfull before
final commit is done. Please kindly point me to the right documentation.

ENV:

MQ 5.2.1, MQSI 2.1 , DB2 7.2.5 all with latest fixpack on Wins2000

The target database is on an AIX box running AIX 4.3.3 and DB2 7.2.5


********* THIS IS WHAT THE DATABASE NODE HAS ******************************************

INSERT
INTO Database.DR.CONTACT (CONTACT_ID,ESTAB_ID,PERSON_ID,TITLE,BLOB_TEST)
VALUES (

Body.Message.CONTACT_ID,
Body.Message.ESTAB_ID,
Body.Message.PERSON_ID,
Body.Message.TITLE,
Body.Message.BLOB_TEST);

INSERT
INTO Database.DR.TEST1 (TEST1COL)
VALUES (

Body.Message.TEST1COL);

INSERT
INTO Database.DR.TEST2 (TEST2COL)
VALUES (

Body.Message.TEST2COL);
Back to top
View user's profile Send private message
kirani
PostPosted: Fri Jun 07, 2002 12:36 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

Narendra,

What do you mean by "all inserts have to be successfull before final commit is done"?

If you want your Database updates to coordinate with MQSeries commit or rollback, you should use 2-phase commit. Your queue manager will act as transaction manager and your database manager will participate in global transaction as resource manager. You will have to configure your message flow to run in Coordinated Transaction mode. By default your transactions are broker coordinated.

In 2-phase commit, if any of your insert statement fails, DB rollback will take place automatically.

Hope this helps.
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
dhaksr
PostPosted: Fri Jun 07, 2002 12:40 pm    Post subject: Reply with quote

Apprentice

Joined: 20 Feb 2002
Posts: 37

To read more about "transaction Co-ordination" you may like to
refer to Administration guide and Intro and Planning Guide of WMQI.

Search for "Transaction" and you will find relevant topics.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » How to use MQSI db node to insert values into mutiple tbls
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.