Hi, The following patch fixes the error from nextval when a re-activation key is generated in Spacewalk 1.5 Postgresql84. Thank you Jan for pointing me the in right direction!
Error message: RHN::Exception: DBD::Pg::st execute failed: ERROR: missing FROM-clause entry for table "rhn_reg_token_seq" at character 8 RHN::DB /usr/lib/perl5/vendor_perl/5.8.8/RHN/DB.pm 228 RHN::Exception::DB::throw RHN::DB::Token /usr/lib/perl5/vendor_perl/5.8.8/RHN/DB/Token.pm 430 RHN::DB::handle_error Patch: --- a/usr/lib/perl5/vendor_perl/5.8.8/RHN/DB/Token.pm 2011-08-05 12:18:52.000000000 -0700 +++ b/usr/lib/perl5/vendor_perl/5.8.8/RHN/DB/Token.pm 2011-08-05 11:58:59.000000000 -0700 @@ -426,7 +426,7 @@ my $dbh = $trans || RHN::DB->connect; if ($self->id == -1) { - my $sth = $dbh->prepare("SELECT sequence_nextval('rhn_reg_token_seq')"); + my $sth = $dbh->prepare("SELECT rhn_reg_token_seq.nextval FROM DUAL"); $sth->execute; my ($id) = $sth->fetchrow; die "No new token id from seq rhn_reg_token_seq (possible error: " . $sth->errstr . ")" unless $id; _______________________________________________ Spacewalk-devel mailing list Spacewalk-devel@redhat.com https://www.redhat.com/mailman/listinfo/spacewalk-devel