ADABAS to DB2 migration

Client thinking of changing ADABAS to DB2 for database storage that is using Natural for Mainframe code. What are pros/cons of doing that? Coding changes to NATURAL code? What are steps involved in beginning that migration? Is it complex or simple? Is there an example somewhere of a NATURAL program calling DB2 as its database that i can see as an example?

You will probably get many similar responses to your query.

  1. Adabas is a far “better” DB than DB2. It is more efficient, more adaptable, etc. If you go to DB2 you lose all of this.

  2. I have heard ratios from 1.5 to 3 of DBA staff size increases.

I will leave it to others to add to the list. I will simpy end with a question:

Would you buy an automobile from a company that makes most of its money selling gasoline? If not, why buy software from a company that makes most of its money selling hardware.

steve

In my opinion, the best approach is a two phased one. First you make your natural code database independent by replacing all I/O commands with calls to an access/update subprogram for each file (object) (ie instead of a Read Loop you replace it with a repeat loop calling a subprogram to return one record at a time). Relatively simple to do but a lot of manual work changing the natural code.
Then you simply replace the access/update subprograms that do the actual I/O (Read, Find etc) with the appropriate DB2 type calls, or whatever database you want to use when you discover just how #$%^ DB2 is.

There is the Natural documentation on the subject, with some examples: http://techcommunity.softwareag.com/ecosystem/documentation/natural/nat425mf/dbms/db2-over.htm#db2-over

If you must use DB2, Natural for DB2 is a nice way to deal with it. A conversion from Adabas to DB2 is aided because many of the Natural statements will remain the same: a FIND on a descriptors is automatically translated into the (several) statements to do the same thing in DB2 (that is, the under-the-covers Adabas direct call is replaced with under-the-covers SQL statements). FIND/READ/HISTOGRAM and STORE/UPDATE/DELETE are automagically handled.

You can also use SQL statements in Natural programs in place of native Natural statements to access DB2.

Obviously, some attention will need to be paid to any MU’s and PE’s in your Adabas files - they won’t translate to DB2 directly and will need more program tweaking (nearly complete re-writes) to convert.

Some concepts don’t have a DB2 equivalent - READ PHYSICAL, GET are two that pop to mind. GET can usually be replaced by a FIND (SELECT). READ PHYSICAL can sometimes be replaced by utilities that unload tables and sometimes by READ LOGICAL.

Hopefully your management has budgetted for larger hardware - memory, CPU, disks and more DBA staff and systems programmers.

Thanks for all the advice.
Would I have to re-code all the references to the database fields using under-scores instead of dashes? Or does Natural for DB2 automatically understand dashes when referencing field names on the DB?

Natural can use underscores or dashes in names, so you can retain DB2 names as they are.