&reftitle.examples;
Basic usage
This simple example shows how to connect, execute a query, print
resulting rows and disconnect from a PostgreSQL database.
PostgreSQL extension overview example
\n";
while ($line = pg_fetch_array($result, null, PGSQL_ASSOC)) {
echo "\t\n";
foreach ($line as $col_value) {
echo "\t\t| $col_value | \n";
}
echo "\t
\n";
}
echo "\n";
// Free resultset
pg_free_result($result);
// Closing connection
pg_close($dbconn);
?>
]]>
Basic usage
These examples contain user defined functions similar to legacy MySQL
functions.
PostgreSQL user defined functions example
0 AND a.attrelid = c.oid
ORDER BY a.attnum;
";
return pg_query($db, $query);
}
?>
]]>