<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/ref.pgsql.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'tr',
  ),
  'this' => 
  array (
    0 => 'function.pg-get-result.php',
    1 => 'pg_get_result',
    2 => 'Get asynchronous query result',
  ),
  'up' => 
  array (
    0 => 'ref.pgsql.php',
    1 => 'PostgreSQL İşlevleri',
  ),
  'prev' => 
  array (
    0 => 'function.pg-get-pid.php',
    1 => 'pg_get_pid',
  ),
  'next' => 
  array (
    0 => 'function.pg-host.php',
    1 => 'pg_host',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'en',
    'path' => 'reference/pgsql/functions/pg-get-result.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="function.pg-get-result" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">pg_get_result</h1>
  <p class="verinfo">(PHP 4 &gt;= 4.2.0, PHP 5, PHP 7, PHP 8)</p><p class="refpurpose"><span class="refname">pg_get_result</span> &mdash; <span class="dc-title">
   Get asynchronous query result
  </span></p>

 </div>

 <div class="refsect1 description" id="refsect1-function.pg-get-result-description">
  <h3 class="title">Açıklama</h3>
  <div class="methodsynopsis dc-description">
   <span class="methodname"><strong>pg_get_result</strong></span>(<span class="methodparam"><span class="type"><a href="class.pgsql-connection.php" class="type PgSql\Connection">PgSql\Connection</a></span> <code class="parameter">$connection</code></span>): <span class="type"><span class="type"><a href="class.pgsql-result.php" class="type PgSql\Result">PgSql\Result</a></span>|<span class="type"><a href="language.types.singleton.php" class="type false">false</a></span></span></div>

  <p class="para rdfs-comment">
   <span class="function"><strong>pg_get_result()</strong></span> gets an <span class="classname"><a href="class.pgsql-result.php" class="classname">PgSql\Result</a></span> instance from
   an asynchronous query executed by
   <span class="function"><a href="function.pg-send-query.php" class="function">pg_send_query()</a></span>, <span class="function"><a href="function.pg-send-query-params.php" class="function">pg_send_query_params()</a></span> or
   <span class="function"><a href="function.pg-send-execute.php" class="function">pg_send_execute()</a></span>.
  </p>
  <p class="para"><span class="function"><a href="function.pg-send-query.php" class="function">pg_send_query()</a></span> and the
   other asynchronous query functions
   can send multiple queries to a PostgreSQL server and
   <span class="function"><strong>pg_get_result()</strong></span> is used to get each query&#039;s results,
   one by one.
  </p>
 </div>

 
 <div class="refsect1 parameters" id="refsect1-function.pg-get-result-parameters">
  <h3 class="title">Bağımsız Değişkenler</h3>
  <p class="para">
   <dl>
    
     <dt><code class="parameter">connection</code></dt>
     <dd>
      <p class="para">
PostgreSQL veritabanı bağlantısı özkaynağı.</p>
     </dd>
    
   </dl>
  </p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.pg-get-result-returnvalues">
  <h3 class="title">Dönen Değerler</h3>
  <p class="para">
   An <span class="classname"><a href="class.pgsql-result.php" class="classname">PgSql\Result</a></span> instance, or <strong><code><a href="reserved.constants.php#constant.false">false</a></code></strong> if no more results are available.
  </p>
 </div>


 <div class="refsect1 changelog" id="refsect1-function.pg-get-result-changelog">
  <h3 class="title">Sürüm Bilgisi</h3>
  <table class="doctable informaltable">
   
    <thead>
     <tr>
      <th>Sürüm: </th>
      <th>Açıklama</th>
     </tr>

    </thead>

    <tbody class="tbody">
     <tr>
 <td>8.1.0</td>
 <td>
  Artık <span class="classname"><a href="class.pgsql-result.php" class="classname">PgSql\Result</a></span> nesnesi dönüyor;
  evvelce bir özkaynak dönerdi.
 </td>
</tr>

     <tr>
 <td>8.1.0</td>
 <td>
  <code class="parameter">bağlantı</code> bağımsız değişkeni artık
  <span class="classname"><a href="class.pgsql-connection.php" class="classname">PgSql\Connection</a></span> nesnesi kabul ediyor, evvelce bir
  özkaynak kabul ederdi.
 </td>
</tr>

    </tbody>
   
  </table>

 </div>


 <div class="refsect1 examples" id="refsect1-function.pg-get-result-examples">
  <h3 class="title">Örnekler</h3>
  <p class="para">
   <div class="example" id="example-1">
    <p><strong>Örnek 1 <span class="function"><strong>pg_get_result()</strong></span> example</strong></p>
    <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br />  $dbconn </span><span style="color: #007700">= </span><span style="color: #0000BB">pg_connect</span><span style="color: #007700">(</span><span style="color: #DD0000">"dbname=publisher"</span><span style="color: #007700">) or die(</span><span style="color: #DD0000">"Could not connect"</span><span style="color: #007700">);<br /><br />  if (!</span><span style="color: #0000BB">pg_connection_busy</span><span style="color: #007700">(</span><span style="color: #0000BB">$dbconn</span><span style="color: #007700">)) {<br />      </span><span style="color: #0000BB">pg_send_query</span><span style="color: #007700">(</span><span style="color: #0000BB">$dbconn</span><span style="color: #007700">, </span><span style="color: #DD0000">"select * from authors; select count(*) from authors;"</span><span style="color: #007700">);<br />  }<br />  <br />  </span><span style="color: #0000BB">$res1 </span><span style="color: #007700">= </span><span style="color: #0000BB">pg_get_result</span><span style="color: #007700">(</span><span style="color: #0000BB">$dbconn</span><span style="color: #007700">);<br />  echo </span><span style="color: #DD0000">"First call to pg_get_result(): </span><span style="color: #0000BB">$res1</span><span style="color: #DD0000">\n"</span><span style="color: #007700">;<br />  </span><span style="color: #0000BB">$rows1 </span><span style="color: #007700">= </span><span style="color: #0000BB">pg_num_rows</span><span style="color: #007700">(</span><span style="color: #0000BB">$res1</span><span style="color: #007700">);<br />  echo </span><span style="color: #DD0000">"</span><span style="color: #0000BB">$res1</span><span style="color: #DD0000"> has </span><span style="color: #0000BB">$rows1</span><span style="color: #DD0000"> records\n\n"</span><span style="color: #007700">;<br />  <br />  </span><span style="color: #0000BB">$res2 </span><span style="color: #007700">= </span><span style="color: #0000BB">pg_get_result</span><span style="color: #007700">(</span><span style="color: #0000BB">$dbconn</span><span style="color: #007700">);<br />  echo </span><span style="color: #DD0000">"Second call to pg_get_result(): </span><span style="color: #0000BB">$res2</span><span style="color: #DD0000">\n"</span><span style="color: #007700">;<br />  </span><span style="color: #0000BB">$rows2 </span><span style="color: #007700">= </span><span style="color: #0000BB">pg_num_rows</span><span style="color: #007700">(</span><span style="color: #0000BB">$res2</span><span style="color: #007700">);<br />  echo </span><span style="color: #DD0000">"</span><span style="color: #0000BB">$res2</span><span style="color: #DD0000"> has </span><span style="color: #0000BB">$rows2</span><span style="color: #DD0000"> records\n"</span><span style="color: #007700">;<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
    </div>

    <div class="example-contents"><p>
Yukarıdaki örneğin çıktısı:</p></div>
    <div class="example-contents screen">
<div class="examplescode"><pre class="examplescode">First call to pg_get_result(): Resource id #3
Resource id #3 has 3 records

Second call to pg_get_result(): Resource id #4
Resource id #4 has 1 records</pre>
</div>
    </div>
   </div> 
  </p>
 </div>


 <div class="refsect1 seealso" id="refsect1-function.pg-get-result-seealso">
  <h3 class="title">Ayrıca Bakınız</h3>
  <p class="para">
   <ul class="simplelist">
    <li><span class="function"><a href="function.pg-send-query.php" class="function" rel="rdfs-seeAlso">pg_send_query()</a> - Sends asynchronous query</span></li>
   </ul>
  </p>
 </div>

</div><?php manual_footer($setup); ?>