Here's what I'm using to verify that results are being returned:
$connstring = "dbname=pub_status user=postgres host=localhost port=5432";
$db = pg_connect($connstring);
$meta = pg_meta_data($db, 'table_definitions');
echo '<pre>';
var_dump($meta);
echo '</pre>';
Which yeilds:
array(2) {
["field_id"]=>
array(5) {
["num"]=>
int(1)
["type"]=>
string(4) "int8"
["len"]=>
int(8)
["not null"]=>
bool(true)
["has default"]=>
bool(true)
}
["field_name"]=>
array(5) {
["num"]=>
int(2)
["type"]=>
string(4) "text"
["len"]=>
int(-1)
["not null"]=>
bool(true)
["has default"]=>
bool(false)
}
}But none of these seem to do anything:
$row_count = pg_num_rows($meta); echo $row_count; -> result a blank web page
$row = pg_fetch_row($meta, 0); echo $row; -> result a blank web page
$row = pg_fetch_array($meta, 0); echo $row; -> result a blank web page
$row = pg_fetch_object($meta, 0); echo $row; -> result a blank web page
What am I doing wrong?
Thanks for any help,
Ken
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

