select open change scope Open full search

PG.CENTER connects PostgreSQL documentation, reference, and ecosystem knowledge. Maintained by Pigsty.

Unsupported versions: 6.3
Historical version. PostgreSQL 6.3 reached end of support in March 2003. See the current manual for supported releases.
SPI_getvalue
PostgreSQL
Prev Next

SPI_getvalue

Name

SPI_getvalue — Returns the string value of the specified attribute
SPI_getvalue(tuple, tupdesc, fnumber)

Inputs

HeapTuple tuple

Input tuple to be examined

TupleDesc tupdesc

Input tuple description

int fnumber

Attribute number

Outputs

char *

Attribute value or NULL if

attribute is NULL
fnumber is out of range (SPI_result set to SPI_ERROR_NOATTRIBUTE)
no output function available (SPI_result set to SPI_ERROR_NOOUTFUNC)

Description

SPI_getvalue returns an external (string) representation of the value of the specified attribute.

Usage

Attribute numbers are 1 based.

Algorithm

Allocates memory as required by the value.


Prev Home Next
SPI_fname Up SPI_getbinval

Report a documentation issue

Read the upstream documentation. For corrections, first check the current manual.