From: Greg Stark Date: Tue, 3 Sep 2013 12:27:34 +0000 (+0100) Subject: Fix thinko in worker_spi, count(*) returns a bigint. Thanks RhodiumToad X-Git-Tag: REL9_3_1~38 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9720164d3426b0a223208b9dc5698264cdb9e2a0;p=postgresql Fix thinko in worker_spi, count(*) returns a bigint. Thanks RhodiumToad --- diff --git a/contrib/worker_spi/worker_spi.c b/contrib/worker_spi/worker_spi.c index 3a75bb3f4e..99501fa566 100644 --- a/contrib/worker_spi/worker_spi.c +++ b/contrib/worker_spi/worker_spi.c @@ -120,7 +120,7 @@ initialize_worker_spi(worktable *table) if (SPI_processed != 1) elog(FATAL, "not a singleton result"); - ntup = DatumGetInt32(SPI_getbinval(SPI_tuptable->vals[0], + ntup = DatumGetInt64(SPI_getbinval(SPI_tuptable->vals[0], SPI_tuptable->tupdesc, 1, &isnull)); if (isnull)