port fix for ejh's pg bug to branch
David Kamholz [Wed, 1 Mar 2006 04:44:48 +0000 (04:44 +0000)]
lib/DBIx/Class/Storage/DBI/Pg.pm

index 7fb6b8c..a1bdc6d 100644 (file)
@@ -23,9 +23,9 @@ sub get_autoinc_seq {
   while (my $col = shift @pri) {
     my $info = $dbh->column_info(undef,$schema,$table,$col)->fetchrow_arrayref;
     if (defined $info->[12] and $info->[12] =~ 
-      /^nextval\('"?([^"']+)"?'::(?:text|regclass)\)/)
+      /^nextval\('([^']+)'::(?:text|regclass)\)/)
     {
-      return $1;
+      return $1; # may need to strip quotes -- see if this works
     } 
   }
 }