For Programmers: Free Programming Magazines  


Home > Archive > PHP DB > April 2004 > Re: [PHP-DB] PostgreSQL lib and character case









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: [PHP-DB] PostgreSQL lib and character case
Doug Thompson

2004-04-28, 8:34 am

Tumurbaatar S. wrote:
> I use pg_fetch_array() to get a record content. But it seems that
> to access elements of the returned associative array, I should
> use lowercase field names. Is there any way to use case-insensitive
> field names?
>


Assuming you want all lower case, convert the form field entry using strtolower().
Martin Marques

2004-04-28, 7:48 pm

El Wednesday 28 April 2004 03:21, Tumurbaatar S. escribi=F3:
> I use pg_fetch_array() to get a record content. But it seems that
> to access elements of the returned associative array, I should
> use lowercase field names. Is there any way to use case-insensitive
> field names?


No. PHP is case-sensitive, so you have to use lower case (unless you made t=
he=20
relation name case-sensitive when you created the PG table).

=2D-=20
19:21:02 up 43 min, 6 users, load average: 1.46, 0.73, 0.58
=2D----------------------------------------------------------------
Mart=EDn Marqu=E9s | select 'mmarques' || '@' || 'unl.edu.ar'
Centro de Telematica | DBA, Programador, Administrador
Universidad Nacional
del Litoral
=2D----------------------------------------------------------------
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com