| A DB2 Data Load 2 | ||||
|
||||
Review: DB2 Express C is loaded with Wordweb database In our first data migration of the Lahman Baseball database from Access to DB2 we used CSV - Comma Separated Values and found the DB2's Control Center LOAD command more than equal to the task. In this the second migration task I use the MySQL-based Wordweb database of word definitions, antonyms, and synonym. Although Wordweb is fewer tables, 12 versus versus 23 for the Lahman database; the Wordweb database has 700,000 records versus the 400,000 in the Lahman database. There is a second major difference - most of the fields in the Lahman database are either integer or floating point as would be expected of baseball statistics while the Wordweb has predominately string fields and some of those are loaded into CLOBs - Character Large Objects. So the data migration had all the look and feel of one of my database contracts including size and string predominating tables but with one notable difference - this migration is onetime while the contract databases are usually monthly or more frequent conversions. So I considered using a utility like Embarcadero's RapidSQL or SQLYog Enterprise - but these tools, as with many others, dumped to Excel or CSV files in order to get to DB2 rather than use a direct connect and transfer approach. So then I switched back to the tried and true LOAD command in DB2's Control Center. I tried to load a CSV file of a table, DEFINITIONS, with two string fields that had managed to defy the Oracle Express loader and forced some extra steps using the RapidSQL Import command. Good fortune - DB2 Control Center's Loader ate up the 126,000 record file with no problems. So that settled the case - I had a data migration plan. The Wordweb Data Migration Plan Now with an empty database I used DB2's Control Center LOAD command to do its trick: Summary In sum, the DB2 Load process was a bit disappointing this time. First, among the free utilities for loading databases, DB2 is frequently not supported. Second, IBM's own Migration Toolkit does not support transfer from MySQL databases with quixotic error messages even for simple two integer field loads. The LOAD module performed admirably well - fast, and yet clear error messages in the LOG file when the LOAD had problems - and those problems were easily fixed. Finally, the LOAD process uncovered a problem in the DERIVED database table. There are 417 duplicate records in which the only difference between the key fields is capitalization - afghani and Afghani. I have gone with a dual solution. In the original MySQL Wordweb database I have left the DERIVED table unchanged. In the DB2 Wordweb database, I have gone with the truncated DERIVED table, awaiting word from the database owner as to which is correct. Top of Page Home Tutorials Developers Weblog Graphics Reviews and Tips |