php-doc-en/reference/pgsql/functions/pg-fetch-result.xml
2002-04-25 01:07:17 +00:00

65 lines
2.5 KiB
XML

<?xml version="1.0" encoding="iso-8859-1"?>
<!-- $Revision: 1.3 $ -->
<!-- splitted from ./en/functions/pgsql.xml, last change in rev 1.82 -->
<refentry id="function.pg-fetch-result">
<refnamediv>
<refname>pg_fetch_result</refname>
<refpurpose>Returns values from a result resource</refpurpose>
</refnamediv>
<refsect1>
<title>Description</title>
<methodsynopsis>
<type>mixed</type><methodname>pg_fetch_result</methodname>
<methodparam><type>resource</type><parameter>result</parameter></methodparam>
<methodparam><type>int</type><parameter>row</parameter></methodparam>
<methodparam><type>mixed</type><parameter>field</parameter></methodparam>
</methodsynopsis>
<para>
<function>pg_fetch_result</function> returns values from a
<parameter>result</parameter> resource returned by
<function>pg_query</function>. <parameter>row</parameter>
is integer. <parameter>field</parameter> is field name(string)
or field index (integer). The <parameter>row</parameter>
and <parameter>field</parameter> specify what cell in the table
of results to return. Row numbering starts from 0. Instead of
naming the field, you may use the field index as an unquoted
number. Field indices start from 0.
</para>
<para>
PostgreSQL has many built in types and only the basic ones are
directly supported here. All forms of <type>integer</type>,
<type>boolean</type> and void
<!-- FIXME: is that still true? PHP supports boolean&null now... -->
<!-- Yes, supporting boolean&null breaks scripts. pg_fetch_array()
can be used instead. I might take of this issue with additional
ini directive. yohgaki@php.net -->
types are
returned as <type>integer</type> values. All forms of float, and
real types are returned as <type>float</type> values. All other
types, including arrays are returned as strings formatted in the
same default PostgreSQL manner that you would see in the
<command>psql</command> program.
</para>
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"../../../../manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->