Re: DB_DataObject, DB and MDB2
| From: | brian | Date: | Tue, 20 Mar 2007 03:59:34 +0000 |
| Subject: | Re: DB_DataObject, DB and MDB2 | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-26879@lists.php.net to get a copy of this message | ||
Albert Acejo wrote:
I just installed the DB_DataObject package and before I got to it I ran into the DB package. Since I'm new to PEAR I checked out the PEAR website and what's the deal with DB and DB_DataObject. From here I found out that the DB_DataObject package is dependent on the DB package which has already been superseded by MDB2. So, I installed MDB2 first thinking that it would be more practical for obvious reasons. But when I was already installing the DB_DataObject package it was still looking for the DB package. So I ended up having MDB2, DB and DB_DataObject all installed. So my questions are: 1. Does having MDB2 installed make a difference?Yes. Having it installed makes it available should you wish to use it (as opposed to, say, DB) in your scripts.
2. Will there be problems with using DB_DataObject when both DB and MDB2 are installed?No. DB_DataObject depends on DB. It doesn't know for MDB2, nor does it care. I have both DB & MDB2 installed, for instance.
3. What's the point of having MDB2 when DB_DataObject still recognizes DB as a dependency?Some PEAR packages have had interesting histories. MDB2 is an entirely different set of files than DB, but both can be utilised to access various databases. Each has its benefits and you should check out the docs to decide which you'd like to use. In the case of DB, one benefit of having it installed is that DB_Data_Object is dependent on it. Thus, in your case, you probably want it. Think of it this way: for general work with a database, you might find that MDB2 gives you a pretty decent interface with which to work. But, should you decide to get all fancy with something like DB_DataObject, you'll need to have DB installed. Think of it as being like a library that some RPM requires. You can otherwise forget that it's even there. [No offense meant to anyone developing or otherwise working with DB. This is just an example situation (which happens to track mine pretty closely).]
I'll be using the DB_DataObject with the Structures_Datagrid to build a web app that has to work with a lot of tables. I will be trying to achieve the same effect that one can get from ASP.NET applicationsYeah, that .NET is pretty far out, bleeding edge stuff. cheers, b