Re: [fw-general] Zend_Db_Select::union() behaving

2009-09-21 Thread william0275
I just noticed this and wasted some time trying to debug my code until I found this bug in the documentation. I'm not sure why and how they added this change. -- View this message in context: http://www.nabble.com/Zend_Db_Select%3A%3Aunion%28%29-behaving-tp21716437p25530470.html Sent from the Ze

Re: [fw-general] Handling MySQL replication with Zend_Db_Adapter and Zend_Db_Table

2009-08-19 Thread william0275
OK here's the source code of my pdo adapter. Please note that it's not perfect because it will only work for Pdo_Mysql. Since the master/slave functionality isn't built-in the framework, there was no way to make it clean by using high level interfaces shared by all adapters etc etc... Also, there

Re: [fw-general] Fetch data from several Databases with Zend_Db_Table_Abstract

2009-02-20 Thread william0275
debussy007 wrote: > > Hi, > > I am using classes extending the Zend_Db_Table_Abstract class. > The Zend_Db_Table_Abstract will use the default adapter to fetch data. > > When I need to fetch data from one DB and then another, I don't know how > to handle it. > I would have, according to the

Re: [fw-general] Insert using Zend DB and an adapter

2009-02-19 Thread william0275
prickett wrote: > > I'm trying to insert a record into a MySql table that has no key. I'm > using an adapter and the following code: > > Zend_Registry::get( "dbAdapter" )->insert( "USERS" , array( "username" => > $this->username , "password" => $this->password ) ); > > > This, however, resul

Re: [fw-general] about zend_db_table and cascading deletes

2009-02-16 Thread william0275
Mark Wright-3 wrote: > > When you use a reference map and dependent tables for cascading row > deletion in the dependent tables how are those rows deleted? Does the > table class issue a sql delete statement or does it go through the row > object? The reason I ask is that I need it to go throug

Re: [fw-general] Delete all the rows of a table

2009-02-12 Thread william0275
Now, just to be fussy, you could even simply do a 'where 1', so $where = '1'; $object->delete($where); :-) Jason Austin wrote: > > $where = '1=1'; > > $object->delete($where); > > - Jason > > -- View this message in context: http://www.nabble.com/Delete-all-the-rows-of-a-table-tp195

Re: Re: [fw-general] How to contact the Zend Framework team about OOP bad practices/suggestions?

2009-02-12 Thread william0275
Allright Matthew, didn't know you were such a small teach. You guys are real commandos :-) A.J. I'm a bit scared of the ticket/patches process etc. Never done that. Maybe I will! -- View this message in context: http://www.nabble.com/How-to-contact-the-Zend-Framework-team-about-OOP-bad-practic

Re: Re: [fw-general] How to contact the Zend Framework team about OOP bad practices/suggestions?

2009-02-12 Thread william0275
Well, I'll tell you what my real problem is. I know ZF is open source, and I love ZF, don't get me wrong... but it's very frustrating to find some part of ZF completely OOP with good practices, and some other parts that are complete hacks. I don't understand this. I guess I'm not used to the open

[fw-general] How to contact the Zend Framework team about OOP bad practices/suggestions?

2009-02-11 Thread william0275
The more I look at the source code of some Zend Framework elements, the more I see bad OOP practices and worse... For example, Zend_Db_Statement and Zend_Db_Statement_Pdo are a frankenstein of OOP. There are methods accessed by the abstract, parent class that *are not* defined in the parent and

[fw-general] Handling MySQL replication with Zend_Db_Adapter and Zend_Db_Table

2009-02-03 Thread william0275
We are switching to a replicated database environment and I've been studying the class hierarchy in the Zend Framework to find the best way to handle this. Since it seems ZF makes poor use of interfaces, classes like Zend_Db_Table checks for an instance of Zend_Db_Adapter instead of a similar inte