ok
Direktori : /opt/alt/postgresql11/usr/share/doc/alt-postgresql11-9.2.24/html/ |
Current File : //opt/alt/postgresql11/usr/share/doc/alt-postgresql11-9.2.24/html/spi-spi-fnumber.html |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <HTML ><HEAD ><TITLE >SPI_fnumber</TITLE ><META NAME="GENERATOR" CONTENT="Modular DocBook HTML Stylesheet Version 1.79"><LINK REV="MADE" HREF="mailto:pgsql-docs@postgresql.org"><LINK REL="HOME" TITLE="PostgreSQL 9.2.24 Documentation" HREF="index.html"><LINK REL="UP" TITLE="Interface Support Functions" HREF="spi-interface-support.html"><LINK REL="PREVIOUS" TITLE="SPI_fname" HREF="spi-spi-fname.html"><LINK REL="NEXT" TITLE="SPI_getvalue" HREF="spi-spi-getvalue.html"><LINK REL="STYLESHEET" TYPE="text/css" HREF="stylesheet.css"><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1"><META NAME="creation" CONTENT="2017-11-06T22:43:11"></HEAD ><BODY CLASS="REFENTRY" ><DIV CLASS="NAVHEADER" ><TABLE SUMMARY="Header navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TH COLSPAN="5" ALIGN="center" VALIGN="bottom" ><A HREF="index.html" >PostgreSQL 9.2.24 Documentation</A ></TH ></TR ><TR ><TD WIDTH="10%" ALIGN="left" VALIGN="top" ><A TITLE="SPI_fname" HREF="spi-spi-fname.html" ACCESSKEY="P" >Prev</A ></TD ><TD WIDTH="10%" ALIGN="left" VALIGN="top" ><A HREF="spi-interface-support.html" ACCESSKEY="U" >Up</A ></TD ><TD WIDTH="60%" ALIGN="center" VALIGN="bottom" ></TD ><TD WIDTH="20%" ALIGN="right" VALIGN="top" ><A TITLE="SPI_getvalue" HREF="spi-spi-getvalue.html" ACCESSKEY="N" >Next</A ></TD ></TR ></TABLE ><HR ALIGN="LEFT" WIDTH="100%"></DIV ><H1 ><A NAME="SPI-SPI-FNUMBER" ></A >SPI_fnumber</H1 ><DIV CLASS="REFNAMEDIV" ><A NAME="AEN61650" ></A ><H2 >Name</H2 >SPI_fnumber -- determine the column number for the specified column name</DIV ><DIV CLASS="REFSYNOPSISDIV" ><A NAME="AEN61655" ></A ><H2 >Synopsis</H2 ><PRE CLASS="SYNOPSIS" >int SPI_fnumber(TupleDesc <TT CLASS="PARAMETER" >rowdesc</TT >, const char * <TT CLASS="PARAMETER" >colname</TT >)</PRE ></DIV ><DIV CLASS="REFSECT1" ><A NAME="AEN61659" ></A ><H2 >Description</H2 ><P > <CODE CLASS="FUNCTION" >SPI_fnumber</CODE > returns the column number for the column with the specified name. </P ><P > If <TT CLASS="PARAMETER" >colname</TT > refers to a system column (e.g., <TT CLASS="LITERAL" >oid</TT >) then the appropriate negative column number will be returned. The caller should be careful to test the return value for exact equality to <TT CLASS="SYMBOL" >SPI_ERROR_NOATTRIBUTE</TT > to detect an error; testing the result for less than or equal to 0 is not correct unless system columns should be rejected. </P ></DIV ><DIV CLASS="REFSECT1" ><A NAME="AEN61667" ></A ><H2 >Arguments</H2 ><P ></P ><DIV CLASS="VARIABLELIST" ><DL ><DT ><TT CLASS="LITERAL" >TupleDesc <TT CLASS="PARAMETER" >rowdesc</TT ></TT ></DT ><DD ><P > input row description </P ></DD ><DT ><TT CLASS="LITERAL" >const char * <TT CLASS="PARAMETER" >colname</TT ></TT ></DT ><DD ><P > column name </P ></DD ></DL ></DIV ></DIV ><DIV CLASS="REFSECT1" ><A NAME="AEN61682" ></A ><H2 >Return Value</H2 ><P > Column number (count starts at 1), or <TT CLASS="SYMBOL" >SPI_ERROR_NOATTRIBUTE</TT > if the named column was not found. </P ></DIV ><DIV CLASS="NAVFOOTER" ><HR ALIGN="LEFT" WIDTH="100%"><TABLE SUMMARY="Footer navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" ><A HREF="spi-spi-fname.html" ACCESSKEY="P" >Prev</A ></TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="index.html" ACCESSKEY="H" >Home</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" ><A HREF="spi-spi-getvalue.html" ACCESSKEY="N" >Next</A ></TD ></TR ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" >SPI_fname</TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="spi-interface-support.html" ACCESSKEY="U" >Up</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" >SPI_getvalue</TD ></TR ></TABLE ></DIV ></BODY ></HTML >