Skip to content
Snippets Groups Projects
Commit c269f0f1 authored by Teodor Sigaev's avatar Teodor Sigaev
Browse files

fix comparison with SPI_processed

parent 22505f47
No related branches found
No related tags found
No related merge requests found
...@@ -218,7 +218,7 @@ get_tsq_Oid(void) ...@@ -218,7 +218,7 @@ get_tsq_Oid(void)
/* internal error */ /* internal error */
elog(ERROR, "SPI_exec to get tsquery oid returns %d", ret); elog(ERROR, "SPI_exec to get tsquery oid returns %d", ret);
if (SPI_processed < 0) if (SPI_processed < 1)
/* internal error */ /* internal error */
elog(ERROR, "there is no tsvector type"); elog(ERROR, "there is no tsvector type");
tsqOid = DatumGetObjectId(SPI_getbinval(SPI_tuptable->vals[0], SPI_tuptable->tupdesc, 1, &isnull)); tsqOid = DatumGetObjectId(SPI_getbinval(SPI_tuptable->vals[0], SPI_tuptable->tupdesc, 1, &isnull));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment