<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <title>Fetches a column from the current row of a result set</title> </head> <body><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="function.sqlite-close.html">sqlite_close</a></div> <div class="next" style="text-align: right; float: right;"><a href="function.sqlite-create-aggregate.html">sqlite_create_aggregate</a></div> <div class="up"><a href="ref.sqlite.html">SQLite Functions</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div><hr /><div id="function.sqlite-column" class="refentry"> <div class="refnamediv"> <h1 class="refname">sqlite_column</h1> <h1 class="refname">SQLiteResult::column</h1> <h1 class="refname">SQLiteUnbuffered::column</h1> <p class="verinfo">(PHP 5 < 5.4.0, PECL sqlite >= 1.0.0)</p><p class="refpurpose"><span class="refname">sqlite_column</span> -- <span class="refname">SQLiteResult::column</span> -- <span class="refname">SQLiteUnbuffered::column</span> — <span class="dc-title">Fetches a column from the current row of a result set</span></p> </div> <div class="refsect1 description" id="refsect1-function.sqlite-column-description"> <h3 class="title">Description</h3> <div class="methodsynopsis dc-description"> <span class="type"><a href="language.pseudo-types.html#language.types.mixed" class="type mixed">mixed</a></span> <span class="methodname"><strong>sqlite_column</strong></span> ( <span class="methodparam"><span class="type">resource</span> <code class="parameter">$result</code></span> , <span class="methodparam"><span class="type"><a href="language.pseudo-types.html#language.types.mixed" class="type mixed">mixed</a></span> <code class="parameter">$index_or_name</code></span> [, <span class="methodparam"><span class="type">bool</span> <code class="parameter">$decode_binary</code><span class="initializer"> = true</span></span> ] )</div> <div class="methodsynopsis dc-description"> <span class="type"><a href="language.pseudo-types.html#language.types.mixed" class="type mixed">mixed</a></span> <span class="methodname"><strong>SQLiteResult::column</strong></span> ( <span class="methodparam"><span class="type"><a href="language.pseudo-types.html#language.types.mixed" class="type mixed">mixed</a></span> <code class="parameter">$index_or_name</code></span> [, <span class="methodparam"><span class="type">bool</span> <code class="parameter">$decode_binary</code><span class="initializer"> = true</span></span> ] )</div> <div class="methodsynopsis dc-description"> <span class="type"><a href="language.pseudo-types.html#language.types.mixed" class="type mixed">mixed</a></span> <span class="methodname"><strong>SQLiteUnbuffered::column</strong></span> ( <span class="methodparam"><span class="type"><a href="language.pseudo-types.html#language.types.mixed" class="type mixed">mixed</a></span> <code class="parameter">$index_or_name</code></span> [, <span class="methodparam"><span class="type">bool</span> <code class="parameter">$decode_binary</code><span class="initializer"> = true</span></span> ] )</div> <p class="para rdfs-comment"> Fetches the value of a column named <em><code class="parameter">index_or_name</code></em> (if it is a string), or of the ordinal column numbered <em><code class="parameter">index_or_name</code></em> (if it is an integer) from the current row of the query result handle <em><code class="parameter">result</code></em>. </p> </div> <div class="refsect1 parameters" id="refsect1-function.sqlite-column-parameters"> <h3 class="title">Parameters</h3> <p class="para"> <dl> <dt> <span class="term"><em><code class="parameter">result</code></em></span> <dd> <p class="para"> The SQLite result resource. This parameter is not required when using the object-oriented method. </p> </dd> </dt> <dt> <span class="term"><em><code class="parameter">index_or_name</code></em></span> <dd> <p class="para"> The column index or name to fetch. </p> </dd> </dt> <dt> <span class="term"><em><code class="parameter">decode_binary</code></em></span> <dd> <p class="para">When the <em><code class="parameter">decode_binary</code></em> parameter is set to <strong><code>TRUE</code></strong> (the default), PHP will decode the binary encoding it applied to the data if it was encoded using the <span class="function"><a href="function.sqlite-escape-string.html" class="function">sqlite_escape_string()</a></span>. You should normally leave this value at its default, unless you are interoperating with databases created by other sqlite capable applications.</p> </dd> </dt> </dl> </p> </div> <div class="refsect1 returnvalues" id="refsect1-function.sqlite-column-returnvalues"> <h3 class="title">Return Values</h3> <p class="para"> Returns the column value. </p> </div> <div class="refsect1 notes" id="refsect1-function.sqlite-column-notes"> <h3 class="title">Notes</h3> <blockquote class="note"><p><strong class="note">Note</strong>: <p class="para"> Use this function when you are iterating a large result set with many columns, or with columns that contain large amounts of data. </p> </p></blockquote> </div> <div class="refsect1 seealso" id="refsect1-function.sqlite-column-seealso"> <h3 class="title">See Also</h3> <p class="para"> <ul class="simplelist"> <li class="member"> <span class="function"><a href="function.sqlite-fetch-string.html" class="function" rel="rdfs-seeAlso">sqlite_fetch_string()</a> - Alias of sqlite_fetch_single</span></li> </ul> </p> </div> </div><hr /><div class="manualnavbar" style="text-align: center;"> <div class="prev" style="text-align: left; float: left;"><a href="function.sqlite-close.html">sqlite_close</a></div> <div class="next" style="text-align: right; float: right;"><a href="function.sqlite-create-aggregate.html">sqlite_create_aggregate</a></div> <div class="up"><a href="ref.sqlite.html">SQLite Functions</a></div> <div class="home"><a href="index.html">PHP Manual</a></div> </div></body></html>