October 2002
Intermediate to advanced
368 pages
7h 12m
English
If you have a simple application that doesn't require complex database interaction, but you still want it to work with multiple databases, then you can create your own set of database wrapper functions.
You have to take into account the different database-specific limitations that may arise and code to the lowest common denominator. That is, you can't use the useful “AUTO_INCREMENT” column feature that is supported in MySQL if you also want to support MS SQL or PostgreSQL databases, since they do not implement that feature. Similarly, MySQL doesn't support secondary keys, so you cannot use that convention.
This next example provides a sample database wrapper that supports MySQL, MS SQL, and PostgreSQL ...
Read now
Unlock full access