|
Posted by Rik on 11/19/87 11:47
rhdyes@gmail.com wrote:
> $qunit = pg_query("SELECT unitid, unitname FROM li_unit ORDER BY
> unitname");
> while($myunits=pg_fetch_array($qunit)){
> $eachid=$myunits["unitid"];
> $eachunit=$myunits["unitname"];
> }
> Any suggestions?
What happens if you instead use pg_fetch_assoc($qunit)?
pg_fetch_array gives both a numerical and a associative array, maybe that's
the issue. It should not give the error in this code, but maybe you ommited
some seemingly insignificant code. I have no PostgreSQL-server, so I can't
test it.
Grtz,
--
Rik Wasmus
Navigation:
[Reply to this message]
|