RE: Need help with finding solution to CDBI bug

[prev] [thread] [next] [Date index for 2004/07/03]

From: robert_creager
Subject: RE: Need help with finding solution to CDBI bug
Date: 04:34 on 03 Jul 2004
Hey Folks,

I just ran across CDBI, and have run into a problem already.  The problem may be the same as referenced in the thread that is the subject of this post.  It seems that the thread references a DELETE action, which is not occuring in my script, so I'm not sure if it's the same problem, or just the same class of problems.

The error I'm receiving is shown below, after the output the script produces.  The script is also included.  The error is emitted during the second round of the inner iterator during the call of $obs->columns.

Thanks for any info.

Cheers,
Rob

index => 246.934, star_id => 1025190, updated => 1
	y => 1191.85, star_id => 1025190, file_id => 6126, smag => 0.009, mag => 8.47748, x => 2026.14
	Can't bind a reference (TASSIV::Catalog=HASH(0x82daa5c)) at /usr/lib/perl5/site_perl/5.8.3/DBIx/ContextualFetch.pm line 51.
	

#!/usr/bin/perl

use strict;
use warnings;

package TASSIV::DBI;

use base qw( Class::DBI );

__PACKAGE__->set_db( 'Main' => 'dbi:Pg:dbname=tassiv', 'robert', undef );

package TASSIV::Welch;

use base qw( TASSIV::DBI );

__PACKAGE__->table( 'welch_index' );
__PACKAGE__->columns( 'Primary' => 'star_id' );
__PACKAGE__->columns( 'Others' => qw/updated index/ );
__PACKAGE__->add_constructor( 'welch_gt' => 'index > ?' );

package TASSIV::Files;

use base qw( TASSIV::DBI );

__PACKAGE__->table( 'files' );
__PACKAGE__->columns( 'Primary' => 'file_id' );
__PACKAGE__->columns( 'Others' => qw/date/ );

__PACKAGE__->has_a( 'file_id' => 'TASSIV::Fits' );

package TASSIV::Fits;

use base qw( TASSIV::DBI );

__PACKAGE__->table( 'fits' );
__PACKAGE__->columns( 'Primary' => 'file_id' );
__PACKAGE__->columns( 'Others' => qw/adc loc darktime exptime/ );

package TASSIV::ObsV;

use base qw( TASSIV::DBI );

__PACKAGE__->table( 'obs_v' );
__PACKAGE__->columns( 'Primary' => 'star_id' );
__PACKAGE__->columns( 'Others' => qw/x y mag smag file_id/ );

__PACKAGE__->has_a( 'file_id' => 'TASSIV::Files' );
__PACKAGE__->has_a( 'star_id' => 'TASSIV::Catalog' );

package TASSIV::Catalog;

use base qw( TASSIV::DBI );

__PACKAGE__->table( 'catalog' );
__PACKAGE__->columns( 'Primary' => 'star_id' );
__PACKAGE__->columns( 'Others' => qw/loc_count loc/ );

__PACKAGE__->might_have( 'welch_index' => 'TASSIV::Welch' => 'index'  );

__PACKAGE__->has_many( 'v' => 'TASSIV::ObsV' );

package main;

my $it = TASSIV::Welch->welch_gt( 200 );

while( my $star = $it->next )
   {
   printf "%s\n", join ', ',
          map { sprintf "%s => %s", $_, $star->$_ } $star->columns;
   my $obj = TASSIV::Catalog->retrieve( $star->star_id );
   while( my $obs = $obj->v->next )
      {
      printf "\t%s\n", join ', ',
             map { sprintf "%s => %s", $_, $obs->$_ } $obs->columns;
      }
   }

(message missing)

Need help with finding solution to CDBI bug
William McKee 11:40 on 19 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 13:19 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 14:06 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 15:14 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 15:23 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 17:07 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
Yuval Kogman 15:30 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
Yuval Kogman 15:37 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 16:12 on 25 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 16:33 on 25 Jun 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 21:47 on 25 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 08:34 on 26 Jun 2004

Re: Need help with finding solution to CDBI bug
Takes Tea at Half Past Three 17:06 on 25 Jun 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 22:13 on 25 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 00:10 on 26 Jun 2004

RE: Need help with finding solution to CDBI bug
robert_creager 04:34 on 03 Jul 2004

Re: Need help with finding solution to CDBI bug
William McKee 17:17 on 05 Jul 2004

Re: Need help with finding solution to CDBI bug
Robert Creager 20:57 on 05 Jul 2004

Re: Need help with finding solution to CDBI bug
Robert Creager 00:22 on 06 Jul 2004

Re: Need help with finding solution to CDBI bug
William McKee 12:50 on 06 Jul 2004

Re: Need help with finding solution to CDBI bug
William McKee 17:05 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
Yuval Kogman 17:18 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 17:41 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
Yuval Kogman 18:04 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 19:20 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
Yuval Kogman 20:16 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 07:34 on 22 Jun 2004

Re: Need help with finding solution to CDBI bug
Yuval Kogman 14:25 on 21 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 20:03 on 22 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 22:44 on 22 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 15:16 on 24 Oct 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 22:15 on 22 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 12:33 on 23 Jun 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 17:17 on 23 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 11:38 on 22 Jun 2004

Re: Need help with finding solution to CDBI bug
merlyn (Randal L. Schwartz) 16:10 on 22 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 13:19 on 22 Jun 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 22:04 on 22 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 12:43 on 23 Jun 2004

Re: Need help with finding solution to CDBI bug
Yuval Kogman 19:52 on 22 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 19:56 on 23 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 12:48 on 23 Jun 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 22:12 on 23 Jun 2004

Re: Need help with finding solution to CDBI bug
Yuval Kogman 23:30 on 22 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 07:08 on 24 Jun 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 13:53 on 24 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 14:51 on 24 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 07:12 on 24 Jun 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 13:50 on 24 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 14:55 on 24 Jun 2004

Re: Need help with finding solution to CDBI bug
Tony Bowden 16:04 on 27 Jun 2004

Re: Need help with finding solution to CDBI bug
Charles Bailey 17:53 on 27 Jun 2004

Re: Need help with finding solution to CDBI bug
William McKee 12:58 on 06 Jul 2004

Generated at 11:35 on 01 Dec 2004 by mariachi v0.52