mirror of
https://github.com/fofolee/uTools-Manuals.git
synced 2025-06-18 05:26:57 +08:00
115 lines
4.2 KiB
HTML
115 lines
4.2 KiB
HTML
<!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>Fetch one result row into array</title>
|
|
</head>
|
|
<body class="docs"><div id="layout">
|
|
<div id="layout-content"><div id="function.odbc-fetch-into" class="refentry">
|
|
<div class="refnamediv">
|
|
<h1 class="refname">odbc_fetch_into</h1>
|
|
<p class="verinfo">(PHP 4, PHP 5, PHP 7)</p><p class="refpurpose"><span class="refname">odbc_fetch_into</span> — <span class="dc-title">Fetch one result row into array</span></p>
|
|
|
|
</div>
|
|
|
|
<div class="refsect1 description" id="refsect1-function.odbc-fetch-into-description">
|
|
<h3 class="title">说明</h3>
|
|
<div class="methodsynopsis dc-description">
|
|
<span class="methodname"><strong>odbc_fetch_into</strong></span>
|
|
( <span class="methodparam"><span class="type">resource</span> <code class="parameter">$result_id</code></span>
|
|
, <span class="methodparam"><span class="type">array</span> <code class="parameter reference">&$result_array</code></span>
|
|
[, <span class="methodparam"><span class="type">int</span> <code class="parameter">$rownumber</code></span>
|
|
] ) : <span class="type">int</span></div>
|
|
|
|
<p class="para rdfs-comment">
|
|
Fetch one result row into <span class="type"><a href="language.types.array.html" class="type array">array</a></span>.
|
|
</p>
|
|
</div>
|
|
|
|
|
|
<div class="refsect1 parameters" id="refsect1-function.odbc-fetch-into-parameters">
|
|
<h3 class="title">参数</h3>
|
|
<p class="para">
|
|
<dl>
|
|
|
|
|
|
<dt>
|
|
<code class="parameter">result_id</code></dt>
|
|
|
|
<dd>
|
|
|
|
<p class="para">
|
|
The result <span class="type"><a href="language.types.resource.html" class="type resource">resource</a></span>.
|
|
</p>
|
|
</dd>
|
|
|
|
|
|
|
|
<dt>
|
|
<code class="parameter">result_array</code></dt>
|
|
|
|
<dd>
|
|
|
|
<p class="para">
|
|
The result <span class="type"><a href="language.types.array.html" class="type array">array</a></span>
|
|
that can be of any type since it will be converted to type
|
|
array. The array will contain the column values starting at array
|
|
index 0.
|
|
</p>
|
|
</dd>
|
|
|
|
|
|
|
|
<dt>
|
|
<code class="parameter">rownumber</code></dt>
|
|
|
|
<dd>
|
|
|
|
<p class="para">
|
|
The row number.
|
|
</p>
|
|
</dd>
|
|
|
|
|
|
</dl>
|
|
|
|
</p>
|
|
</div>
|
|
|
|
|
|
<div class="refsect1 returnvalues" id="refsect1-function.odbc-fetch-into-returnvalues">
|
|
<h3 class="title">返回值</h3>
|
|
<p class="para">
|
|
Returns the number of columns in the result;
|
|
<strong><code>FALSE</code></strong> on error.
|
|
</p>
|
|
</div>
|
|
|
|
|
|
<div class="refsect1 examples" id="refsect1-function.odbc-fetch-into-examples">
|
|
<h3 class="title">范例</h3>
|
|
<p class="para">
|
|
<div class="example" id="example-982">
|
|
<p><strong>Example #1 <span class="function"><strong>odbc_fetch_into()</strong></span> examples</strong></p>
|
|
<div class="example-contents">
|
|
<div class="phpcode"><pre><span style="color: #000000">
|
|
<span style="color: #0000BB"><?php<br />$rc </span><span style="color: #007700">= </span><span style="color: #0000BB">odbc_fetch_into</span><span style="color: #007700">(</span><span style="color: #0000BB">$res_id</span><span style="color: #007700">, </span><span style="color: #0000BB">$my_array</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">?></span>
|
|
</span>
|
|
</pre></div>
|
|
</div>
|
|
|
|
<div class="example-contents"><p>
|
|
or
|
|
</p></div>
|
|
<div class="example-contents">
|
|
<div class="phpcode"><pre><span style="color: #000000">
|
|
<span style="color: #0000BB"><?php<br />$rc </span><span style="color: #007700">= </span><span style="color: #0000BB">odbc_fetch_into</span><span style="color: #007700">(</span><span style="color: #0000BB">$res_id</span><span style="color: #007700">, </span><span style="color: #0000BB">$my_array</span><span style="color: #007700">, </span><span style="color: #0000BB">2</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">?></span>
|
|
</span>
|
|
</pre></div>
|
|
</div>
|
|
|
|
</div>
|
|
</p>
|
|
</div>
|
|
|
|
</div></div></div></body></html> |