I am making a function (PHP). In this function it basically uses the dbms specified and connects, submits the appropriate query, <insert my problem here>, and disconnects. DBMSs include MySQL, MSSQL, Postgres, and Oracle.
I am assuming that outside of this function, the user would not have access to specified DMBS, so whatever results I get from it I need to convert to something usable like a regular PHP variable/array/object.
I don't know the best way to do this (and have only had extended experience with MySQL), so I would like to know how going about handling each return so that they all come out to PHP relatively the same. I would extremely appreciate an example in any case.