OCI_ASSOC returns key with upper case string

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

 



Hello,
First let me say that I am not sure if this is PHP problem or Oracle. I posted 
this earlier in php-general, but after looking at the available mailing lists 
again, I thought this forum would be more appropriate. Sorry if someone get 
double post. 

I have a class that contains API for using postgresql, mysql, or oracle 
database so switching database should be "in theory" just changing an 
argument for me. 
To make this sort, let just say that the return of a SELECT statement is 
always in associative array, using either :
"pg_fetch_assoc" for pgsql
"mysql_fetch_assoc" for mysql
"ocifetchinto" with OCI_ASSOC flag for Oracle 9

Now, pg_fetch_assoc and mysql_fetch_assoc return the associate array with the 
key in lower case. But ocifetchinto returns the key in UPPER case. So this 
discrepancy makes my code not as portable as I would like it. 
Furthermore, the example here:
http://us2.php.net/manual/en/function.ocifetchinto.php

doesn't even work, because it uses lower case as the associative array key.

Why is this the case? Is this PHP problem or Oracle config problem? Either 
way, can anyone suggest a solutions? Of course I can do all kind of array 
manipulation in my API to make the key lower case, but that wouldn't be very 
elegant and efficient

Thanks in advance for any help.
RDB
-- 
Reuben D. Budiardja
-------------------------------------------------
/"\  ASCII Ribbon Campaign against HTML    
\ /  email and proprietary format      
 X   attachments.
/ \
-------------------------------------------------
Have you been used by Microsoft today? 
Choose your life. Choose freedom. 
Choose LINUX.
-------------------------------------------------


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux