© Bjarke Wedemeijer,

for my curriculum viteeeee, klik her.

for monkey DBA, MonkeyDBA

 

For years, I have planned to make a website only for databases. A website which is totally dedicated to the totally over-estimated, paid, and idiotic roles of DBA’s. Every company using databases knows how difficult those DBA’s can be. DBA’s are always “vendor” dependant. So, if you unfortunately meet a mainframe DB2 z/OS DBA he will tell you that the only database in the world that functions and scales; is, uh, DB2 on z/OS, definitely not DB2 LUW which is also an IBM product, only that one is running on “plastic platforms”. If you take the next DBA which is specialized in Oracle, he will tell you that Oracle is the king of databases, and the next DBA which is a “pepsi-drinking-teenager” using Microsoft SQL Server, he will tell you that SQL Server is much quicker to setup and outperforms even DB2 on the z/OS. In the corner of the room you find a silly Sybase DBA who is reading “How to convert from Sybase to SQL Server” guide. And there are a bunch of other databases like MySQL, Ingres, and Informix, those are tiny players on the market, but they have some nice features.

 

On this site, I only look into Oracle, SQL Server (2000&2005), Sybase, DB2 LUW, and DB2 for z/OS. Of course, no information, which is company-sensitive will I provide, all information can be looked up in all those millions of pages of documentation which every professional database must have (why, I don’t know!). So, what am I going to do on this site? I will show that one can be a DBA for all those professional databases! I’ll show how you can cope with all the info. If you ask a DBA if he can cope with more than 2 databases types, he will say you are nuts

 

a)      One database is difficult enough, be an expert in only one database, be a specialist. I’ll show you how to be a specialist on all databases!

b)      The amount of documentation is too much, I’ll show you how to cope with all the information!.

c)      You can’t handle so many types of databases, within the working-hours, I’ll show you that you can!

d)      I’ll show you that narrowing into 1 database as a DBA will narrow your mind!

e)      I’ll show you that every database is functionally equal, only features differ!

f)        I’ll show you that even operating systems are databases!

g)      I’ll show you that even notepad is a database!

h)      I’ll show you that DBA is an easy job, know the basics, and the differences between the databases and you are king!

i)        Use your mind in stead of “how-to” or manuals, manuals can lie, always test your own hypothesis!

 

If you understand that all this is possible, than you have a change, use the monkey DBA link on the top to see the differences between the databases,

and all the syntax stuff, and specialized commands. I’m not a DBA specialist, I’m the monkey DBA.

 

So, lets start with the basics. All platforms have memory, CPU, disks, CD-ROM drives etc etc, So, basic computer science stuff can be used on all platforms. Disk are slower than CPU, there is some OS booting stuff or “IPL” on the z/OS, semaphores, latches, etc etc. There are users, there are logs (error), so if you can administer an Oracle installation on Linux, you probably also can do it on a z/OS – the initial OS commands are different, but that is something you can look up in a book.

 

if you can administer database A on platform X, you probably also can manage database A on platform Y.

 

Now we got rid of the stupid platform discussion. Yeah, intel CPUs are faster than mainframe CPU’s. RISC vs. CICS bla bla bla. It’s still a micro-processor isn’t it ? The days were everybody knew all the assembler instructions on the mainframe CPU’s or Intel 8088 are over. There are too many CPU’s and they are too complex to know them all. So, buy a high level programming language, a good one is C (C++, C# or whatever they call it). If I know C, I can write programs which can run on windows, AIX, Solaris, AS/4000, z/OS, etc. I once showed a system programmer in the bank I worked for that one program can run on all platforms. I showed them the following C-program which I ran on AIX, Sun Solaris, Windows, and Z/OS mainframe without any modifications. Z/OS mainframes are in fact 80% Unix machines, but I can tell you later why.

 

#include <stdio.h>

main()

{

                      printf(“ hello world \n”);

}

 

Now we have general programming language which runs on all platforms:

 

if you can run your program in C, on platform X, you probably also can run it on platform Y.

 

Which language do you think databases are written in ? Basic, Cobol, PL/1 ? Take a hex editor, and look into the DBMS binaries. I guarantee you that Oracle, SQL Server, DB2 LUW, Sybase and probably also all the small (in market shareJ) databases like Ingres and Informix all are coded in C/C++. On DB2 z/OS the good old system R is coded is some internal IBM stuff and assembler, but all new features are coded in C or C++, and they have ported several features from DB2 LUW (Linux Unix Windows) as C-sources into the DB2 z/OS environment. I bet that v9 of DB2 z/OS has more C-code than before, you wonder why? All the ‘good-old’ mainframe programmers are lying in the sun enjoying there otium, the new programmer only learned C, or C++ J. So almost all databases are coded in C, they probably use the same functions to allocate memory, read from disk etc.

 

                                            if all databases are coded in C, all database code use probably the same basic functions.

 

Since the professional database companies have guides like “how to move from Oracle to SQL Server in 24 hours”, and vice versa, there must be some basic database functionality which is equal for all databases. A database is just a C/C++ program which reads data from disk into memory, and send it to the user upon request. Since the user cannot write “Send me block 3 from sector 6 from harddisk 2 but only if the data contains somewhere ‘Bjarke’”, the database software represents the data as datasets which can be retrieved or modified by a general language ‘SQL’…oops, a general language again ?  Read the books written by CODD or DATE if you want to know more about the theoretical part of databases, the major issue is:

 

all databases have a common subset of SQL, so if you know the common subset you can query/modify any database.

 

We have shown that the platform discussion is ridiculous so we can support a database on any platform ! Databases are coded in the same language so there are common principles like disk reads, cpu usage, parsing which are equal for all databases! All queries against any database use a common subset language (SQL) and that is nice, if we know SQL we know SQL for all the databases!

 

WHAT IS DIFFERENT?

 

The differences are:

·        backup & recovery.

·        tracing mechanisms.

·        high availability features.

·        client connectivity methods.

·        management infrastructure.

·        documentation.

·        PANIC, HELP, DISASTER!

 

If one knows these 7 things of every database you cope with, you are on the right track. There are more exotic features like olap, holap, cubes, xml, and other marketing stuff. My point is, if you can administrer one database, you can administrer also a second one. The only thing you have to know is backup/restore, tracing, high availability features, client connectivity, general management infrastructure, where is the HELP key, and PANIC, HELP, DISASTER!. PANIC, HELP, DISASTER is the situation where everything goes wrong, and you can not figure out what is wrong. If you know the right features in every database, you can find out. If you were the programmer who programmed the bug, how would you find out the bug, or bad piece of code ? All database vendors have special traces, or programs to find errors, bugs, and “bad” code, if you know the tools they use in the lab, you can use them too!

 

I once had a newbie-mainframe-programmer who made a complete scan of a table with 100 millions rows, he needed only 5 rows from the table. He had a Pepsi in his hand, so he tells me that SQL Server can scan those rows faster than the mainframe can. Whether he was right or wrong is not important, the question should be “why do you let the DBMS read 100 million rows, for only returning 5 rows”. No matter whether the database is called Oracle, Sybase, or something else, there is one golden rule that accounts for all databases:

 

The amount of work done by the database should be in balance with the business needs.

 

If you are scanning those 100 millions rows and you return 5 rows in a data warehouse configuration, this might be ok. If you are dealing with real-time-online applications, this is not going to work. If you are buying a 16-way AIX machine and pay oracle trillions of dollars to manage a 10GB database that might be ok,

it depends on the business needs. One the other hand, a little Intel server with a SQL Server may do the same trick – it depends on business needs!

 

The most important thing about databases, is knowledge. You cannot read and know everything in detail, the ever growing database products have to many features.

Document where you can find the documentation!

 

                                           

Enjoy Monkey DBA,

 

Bjarke.