[CDBI] Re: Class::DBI internal column swapping wierdness ?

Richard.Foley at t-online.de Richard.Foley at t-online.de
Thu Sep 29 16:37:05 BST 2005


What a lot of doubting Thomas' - here you go :-)

  EnabledDisabled.pm and YesNo.pm attached.

As you can see, they're nearly completely empty and should not explain
such wierd behaviour.  Again, if the problem were related to the code,
(in these 2 nearly empty modules), why should the behaviour go away,
when I reload the object from the database with an explicit retrieve().

...?

-- 
Ciao
Richard Foley
Ciao - shorter than aufwiedersehen

http://www.apress.com/book/bookDisplay.html?bID=399
http://www.oreilly.com/catalog/perldebugpr/ 

-----Original Message-----
> Date: Thu, 29 Sep 2005 16:51:08 +0200
> Subject: Re: Class::DBI internal column swapping wierdness ?
> From: Michael Peters 
> To: Richard.Foley at rfi.net

> 
> 
> Richard.Foley at t-online.de wrote:
> > Michael,
> > 
> > These 2 packages are almost completely empty, and do not refer to
> > any other tables themselves.  They cannot, of course, because they
> > are being used by multiple other tables/modules by different names,
> > in a one-way relationship.
> > 
> 
> And you're sure that these two classes (Att::EnabledDisabled and
> Att::YesNo) aren't the problem? If you don't mind, please show their
> code.
> 
> 
> > I have not seen this behaviour before, although it
> > appears to be consistent now that I have found this single record
> > behaving in this manner, repeatedly.  I'm quite prepared to believe
> > I'm doing something daft, but it doesn't look like it, yet, (famous
> > last words...)  It's very wierd.
> > 
> 
> Does it just behave differently for certain records? or certain
> tables? Are these 2 classes (Att::EnabledDisabled and Att::YesNo) used
> anywhere else?
> 
> --
> Michael Peters
> Developer
> Plus Three, LP
> 
> 
> 
-------------- next part --------------
=head1 NAME

Att::YesNo - YesNo methods for Att

=cut

package Att::YesNo;

use strict;
use base qw(Att::Dbi);

=head1 DEFINITIONS

=over 4

=item tablename

=cut

__PACKAGE__->table  ('yesno');

=item primary key

=cut

__PACKAGE__->columns(Primary	=> qw(name));

=item essential columns

=cut

__PACKAGE__->columns(Essential    => qw(
    created created_by modified modified_by
    title
));

sub isaflag { return 1 }

=back

=cut

0101;
-------------- next part --------------
=head1 NAME

Att::EnabledDisabled - EnabledDisabled methods for Att

=cut

package Att::EnabledDisabled;

use strict;
use base qw(Att::Dbi);

=head1 DEFINITIONS

=over 4

=item tablename

=cut

__PACKAGE__->table  ('enableddisabled');

=item primary key

=cut

__PACKAGE__->columns(Primary	=> qw(name));

=item essential columns

=cut

__PACKAGE__->columns(Essential    => qw(
    created created_by modified modified_by
    title
));

sub isaflag { return 1 }

=back

=cut

0101;


More information about the ClassDBI mailing list