Re: 3.0.10

From: Date: Tue, 20 Jul 1999 20:38:03 +0000
Subject: Re: 3.0.10
References: 1 2 3  Groups: php.dev 
Request: Send a blank email to php-dev+get-7263@lists.php.net to get a copy of this message
> > >And in case nobody picked up on it, the dbm abstraction layer (and > > >what I plan to do with the PDF libs) are in some ways a warmup for > > >doing an SQL database abstraction layer. > > > > Can you tell us more about that SQL abstraction layer that you are > > planning? What will support? Just queries, or also creation and changing > > tables, transactions, cursorsm etc.? > > A DBI like interface would be cool - and an important argument to > convert Perl users. I'm currently working on something along this line. It's completly based in php though. I've mirrored some of the functionality in DBI::DBD in such as there is a database interface object, and then a query driver. I'm going to create a high level abstraction class that will allow you to do the following : /* Just like dbi::dbd */ $my_db = new Db( 'Mysql' ); $my_db->database = 'foo'; $my_db->user_name = 'bar'; $my_query = $my_db->Prepare( 'SELECT * FROM A_TABLE;' ); while( list( $my_values ) = $my_query->FetchRow() ) { } This is the same as : $my_db = new Mysql_Db(); $my_db->database = 'foo'; $my_db->user_name = 'bar'; $my_query = $my_db->Prepare( 'SELECT * FROM A_TABLE;' ); while( list( $my_values ) = $my_query->FetchRow() ) { } The difference is that the Db class wraps a call to the various database drivers and returns them up. You can take a look at the incomplete documentation on my devel box, at http://slipgate.echozone.com/docs -- ________________________________________________________________________ Jason "ZeroDiVide" Orcutt Current Projects : [IMP] - http://web.horde.org/imp [NAG] - http://web.horde.org/nag Current Todo : [ME] - Down for maintiance [IMP] - http://horde-todo.atcjet.net

« previous php.dev (#7263) next »