you are looking for a framework, i think. php has functions to maniulate database, but not in abstract mode like recorsets in asp, in a common api.
you should to search a framework for database, writed lower level like c extensions or higger level in php.
Pear has many frameworks, in php, included database, you can find on
http://pear.php.net/package-info.php?pacid=46
bye