Search Postgresql Archives

Mixed Case column names (php 4.3.5 & pg 7.4.2)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello All,

    I have a very simple page that illustrates an issue I am having. (Please
assume that dbConnect() returns a vaild connection and there is at least 1
record returned)

<?

 include('GlobalFunctions.php');

 $oConn = dbConnect();

  $rsTest = pg_exec('SELECT "ridStudent" FROM "tblStudent"');

  echo pg_fetch_result($rsTest,0,"ridstudent");

 pg_close($oConn);


?>

Can anyone please explain why this doesn't work.  I know that I can use an
all lowercase alias in the query, but there HAS to be an easier way.  I
currently am referencing everything by ordinal, that is going to bite me
whenever someone decides to make a "simple" DB change.  Is this pg_fetch
results even the best thing to use?

Thanks
Matthew




---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux