[freeside] patch not working from November 19

ivan ivan at 420.am
Fri Dec 19 16:04:41 PST 2003


The patch I posted previously was in error.  Do not apply it.

Try a DBD::Pg 1.32 snapshot from gborg CVS
http://gborg.postgresql.org/project/dbdpg/projdisplay.php 
and report the results.

If this is fixed in DBD::Pg 1.32 I will update the dependancies.

-- 
_ivan


On Mon, Dec 15, 2003 at 10:28:05AM -0500, Jeremy Davis wrote:
> On Wed, Nov 19, 2003 at 05:39:30PM +1100, Bob Purdon wrote:
> > Cannot specify both sql_type and pg_type at
> > /usr/local/lib/perl5/site_perl/5.6.1/FS/Record.pm line 272.
> 
> I got the same error as this gentleman did.  I applied the patch, I first
> tried the changes manual after researching your/Ivan's post to the author of
> DBD::Pg on the 19th then happened to stumble across the post at the bottom.
> Either way I applied the patch and now instead of Cannot specify both
> sql_type and pg_type, I get:
> 
>  DBI::st=HASH(0x848afc8)->bind_param(...): attribute parameter '4' is not a
> hash ref at /usr/lib/perl5/site_perl/5.8.0/FS/Record.pm line 272
> 
> What should I do?  I attempted to downgrade to 1.21 but it created problems
> at first.  I didn't dig to deep into the later.  Any advice would be greatly
> appreciated.
> 
> Sincerely,
> 
> Jeremy Davis
> 
> 
> This is a bug in DBD::Pg 1.31.  The following patch should work around
> the problem:
> 
> diff -u -r1.76 Record.pm
> --- Record.pm   4 Nov 2003 10:57:05 -0000       1.76
> +++ Record.pm   19 Nov 2003 18:09:38 -0000
> @@ -313,9 +313,9 @@
>      if ( $record->{$field} =~ /^\d+(\.\d+)?$/
>           && $dbdef->table($table)->column($field)->type =~ /(int|serial)/i
>      ) {
> -      $sth->bind_param($bind++, $record->{$field}, { TYPE =>
> SQL_INTEGER } );
> +      $sth->bind_param($bind++, $record->{$field}, SQL_INTEGER );
>      } else {
> -      $sth->bind_param($bind++, $record->{$field}, { TYPE =>
> SQL_VARCHAR } );
> +      $sth->bind_param($bind++, $record->{$field}, SQL_VARCHAR );
>      }
>    }
> 

-- 
_ivan



More information about the freeside-users mailing list