Hi, Can anyone give me any pointers for creating a database abstraction class ? I know there are a few out there already, but I'm doing this purely as an OO learning exercise. I'm only at the paper design right now and I've only got this far;
Properties: Persistent - Persistent connection ? (Boolean) User - Username (String) Pass - Password (String) Host - Database Server (String) Port - Database Port (3306 default for MySQL Query - Query to run (String) Result - Query Result (String) Error - Error returned (if any) NumRows - Num of rows returned from query (int) NumCols - Num od columns returned from query (int) RowsPerPage - Number of rows per page PagingOn - Return results in page ? (Boolean) CurrentPage - Current page number (int) Methods: Connect - Connect to db Close - Close connection SelectDB - Select database RunQuery - Execute query OutputTable - Output query results in table OutputPage - Outputs page of query results (calls OutputTable) FetchRow - Returns single row from query CreateLink - Creates HTML <A> tags for drill down queries Are there any other properties/methods that would be useful ? Links/advice welcome (read "needed") Cheers, Nick This private and confidential e-mail has been sent to you by Egg. The Egg group of companies includes Egg Banking plc (registered no. 2999842), Egg Financial Products Ltd (registered no. 3319027) and Egg Investments Ltd (registered no. 3403963) which carries out investment business on behalf of Egg and is regulated by the Financial Services Authority. Registered in England and Wales. Registered offices: 1 Waterhouse Square, 138-142 Holborn, London EC1N 2NA. If you are not the intended recipient of this e-mail and have received it in error, please notify the sender by replying with 'received in error' as the subject and then delete it from your mailbox. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php