blob: 6982a84493e86ef5a546dcfcbae8956594a92bb5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
<?php
error_reporting(E_ALL);
include 'config.inc';
$db = pg_connect($conn_str);
$sql = "SELECT * FROM $table_name";
$result = pg_query($db, $sql) or die('Cannot qeury db');
$rows = pg_num_rows($result);
$rec = pg_fetch_object($result, 1);
var_dump($rec);
$rec = pg_fetch_array($result, 1);
var_dump($rec);
$rec = pg_fetch_row($result, 1);
var_dump($rec);
echo "Ok\n";
?>
|