Re: [RDBO] Duplicate many-to-many map rows

2007-03-23 Thread rose
On Fri, 23 Mar 2007, John Siracusa wrote: > If you add the same bar twice, it'll add a new mapping each time. > That's what add_bars() does. Given that Rose knows that this is a many-to-many relationship between foos and bars, isn't it pretty far-fetched that you would actually want duplicate rec

Re: [RDBO] Paging with Iterators

2007-03-23 Thread rose
On Fri, 23 Mar 2007 [EMAIL PROTECTED] wrote: > my $itr = Bar->get_bars_iterator(); Sorry, this should read my $itr = Bar::Manager->get_bars_iterator(); of course as it refers to the manager class. -- Mike Mike Schilli [EMAIL PROTECTED] > while($itr->next()) { > > won't work be

[RDBO] Paging with Iterators

2007-03-23 Thread rose
I'm using Rose with a fairly large MySQL database and using an iterator like my $itr = Bar->get_bars_iterator(); while($itr->next()) { won't work because by default, an iterator will read in all records from the DB, which won't fit into memory. Using my $itr = Bar->get_bars_iterator

[RDBO] Using the results of make_methods()

2007-03-23 Thread Jeff Chimene
Hi, Given the following file in the Access/ directory created by make_methods(): package inspectDB::Access::Manager; use base qw(Rose::DB::Object::Manager); use inspectDB::Access; sub object_class { 'inspectDB::Access' } __ PACKAGE__->make_manager_methods('access'); 1; and

Re: [RDBO] Duplicate many-to-many map rows

2007-03-23 Thread John Siracusa
On 3/10/07, Mike Schilli <[EMAIL PROTECTED]> wrote: > $foo->add_bars({ string => "I am Bar" }); > $foo->save(); > > The first time this is run, records for both "I am Foo" in foos and "I am Bar" > in bars are created [...] and the relationship table contains the mapping: > > mysql> sele

Re: [RDBO] Column.pm bug w/patch

2007-03-23 Thread John Siracusa
On 3/10/07, Cory Bennett <[EMAIL PROTECTED]> wrote: > I have a column with inflate/deflate triggers and sometimes I get this error: > > Not an ARRAY reference at ./Rose/DB/Object/Metadata/Column.pm line 1087 Sorry for the delay. Your patch is applied to SVN. Thanks! -John -