Gaetano Giunta wrote:
> Thomas Koch a écrit :
>> Hi Peter,
>>
>> I've had the issue with uppercase myself once and it is since then
>> documented at:
>>
>> http://ezcomponents.org/docs/tutorials/Database#restrictions
>>
>> The import code is at
>> Database/handler.php, line 91:
>>         $this->setAttribute( PDO::ATTR_CASE, PDO::CASE_LOWER );
>>
>> This means, that all identifiers needs to be lower case. This is
>> enforced to keep code compatibility across all supported databases.
>>   
> mmmh...
> Thinking more about it: if we set /PDO::CASE_LOWER/ on the connection 
> handle, we will get back from the db lowercase column names.
> What if we then changed the quoteidentifier method for Oracle to not 
> add the quotes around the identifier name by default, and only add 
> them when a space or other invalid char is detected?
We would have to check for Oracle Keywords, too. Or quoteidentifier() 
could be configured to default to upper or lower case, depending on 
database and/or user preference.
> That would mean that it could be feasible to use an Oracle db that has 
> uppercase column names, and treat them as lowercase in php code.
> Much more user friendly imho, especially to allow usage of ezcdb on 
> existing datatases, that are quite likely to have uppercase-named 
> objects.
> //
Regards,

Peter
>> I'm sorry, but I've no idea about the second issue. Wait a bit if the eZ
>> guys will answer you.
>>
>> Cheers, Thomas Koch
>>
>>
>>
>> Am Friday 27 February 2009 19:02:31 schrieb Peter Hopfgartner:
>>  
>>> Dear ezComnuity,
>>>
>>> I would like to use the Tree functionality for a database located in a
>>> Oracle database. Unfortunatly I hava a couple of problems, that may be
>>> caused by the fact that
>>>
>>>  * I'm new to ezComponents
>>>  * I'm new to Oracle
>>>
>>> I defined the table as
>>>
>>> CREATE TABLE taxonomy
>>>   (
>>>     id        NUMBER PRIMARY KEY,
>>>     parent_id NUMBER            ,
>>>     path      VARCHAR2(255)
>>>   );
>>>
>>> Since Oracle defaults to UPPER CASE, the name of the table is 
>>> "TAXONOMY".
>>>
>>> When I try to use ezcTreeMaterializedPath, I see that would like to run
>>> a query like <INSERT INTO "taxonomy" ( path ) VALUES ( 0 )>. Since the
>>> table name is quoted, Oracle does searches for a table called
>>> "taxonomy", not "TAXONOMY".  So my question is: what are the
>>> convenctions when using ez Componets on Oracle? Should all table names
>>> turned to lower case? Is there a database setting, which basically 
>>> tells
>>> Oracle to not care about case sensitivity? Or even better, a parameter
>>> within ez, like the option "auto_quote" in PEAR::MDB2, so that names 
>>> are
>>> not quoted.
>>>
>>> Out of curiosity, I tried to create a new table named "taxonomy". The
>>> next  stop arrived with a flashing  message like "driver does not
>>> support lastInsertId()".  Is this fixable? Should I have a look at it?
>>> Obviously, as a workaroud I may chose to create the id myself and turn
>>> $tree->autoId = false; This works!
>>>
>>> Regards,
>>>
>>> Peter
>>>
>>> -- 
>>>
>>> Dott. Peter Hopfgartner
>>>
>>> R3 GIS Srl - GmbH
>>> Via Johann Kravogl-Str. 2
>>> I-39012 Meran/Merano (BZ)
>>> Email: peter.hopfgart...@r3-gis.com
>>> Tel. : +39 0473 494949
>>> Fax  : +39 0473 069902
>>> www  : http://www.r3-gis.com
>>>     
>>
>>
>>   
>
>


-- 
 
Dott. Peter Hopfgartner
 
R3 GIS Srl - GmbH
Via Johann Kravogl-Str. 2
I-39012 Meran/Merano (BZ)
Email: peter.hopfgart...@r3-gis.com
Tel. : +39 0473 494949
Fax  : +39 0473 069902
www  : http://www.r3-gis.com

-- 
Components mailing list
Components@lists.ez.no
http://lists.ez.no/mailman/listinfo/components

Reply via email to