If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > IBM Migration Toolkit 2.0

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 04-16-10, 08:14
GeorgeLazlo GeorgeLazlo is offline
Registered User
 
Join Date: Mar 2010
Posts: 7
IBM Migration Toolkit 2.0

Hi,

I used the IBM Migration Toolkit 2.0 to convert an MSSQL database schema to DB2 9.7. When I converted MSSQL stored procedures I recognized two issues, and I don't understand why the toolkit inserted some code parts.

All stored procedure has the following code:
Code:
DECLARE SQLSTATE CHAR(5) DEFAULT '00000';
DECLARE l_error CHAR(5) DEFAULT '00000';
DECLARE CONTINUE HANDLER FOR NOT FOUND
    SET l_error = '00000';
DECLARE CONTINUE HANDLER FOR SQLEXCEPTION, SQLWARNING
    BEGIN
        SET l_error = SQLSTATE;
        IF SUBSTR(l_error, 1, 1) >= '5'
           AND SUBSTR(l_error, 1, 1) <= '9' THEN 
            RESIGNAL;
        END IF;
    END;
This code part is really necessary?

The other interesting issue is:
The tool uses a COMMIT; statement after _each_ update and insert statement in the stored procedure. If I remove these COMMIT; statements the procedures are still working fine, so I don't understand why these statements are necessary? (the original MSSQL code did not contain these COMMIT statements)

Thx for answers!

Lazlo
Reply With Quote
Reply

Tags
ibm migration toolkit

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On