#5716: Lower case table names causes function describe to fail in firebird
-------------------------+--------------------------------------------------
    Reporter:  abbas     |          Type:  Bug     
      Status:  new       |      Priority:  Medium  
   Milestone:  1.2.x.x   |     Component:  Firebird
     Version:  RC3       |      Severity:  Major   
    Keywords:  firebird  |   Php_version:  n/a     
Cake_version:            |  
-------------------------+--------------------------------------------------
 The issue is that firebird turns the table (or for that matter even field)
 names to upper case if they are not quoted in query.

 Now if i use following statement to create my table then the table name
 will be in lowercase

 {{{
 CREATE TABLE "mytable" (....);
 }}}

 So the query to describe table should also have the name enclosed in
 quotes. But the describe function in firebird driver does not quotes the
 name and hence if a table name is in lower case then describe function
 will give errors (table not found).

 The code segment is (function describe in firebird driver)

 {{{
 $sql = "SELECT * FROM " . $this->fullTableName($model, false);
 }}}

 Possible fix

 {{{
 $sql = "SELECT * FROM \"" . $this->fullTableName($model, false) . "\"";
 }}}

 If developer uses uppercase table names then (s)he should specify it in
 $useTable.

-- 
Ticket URL: <https://trac.cakephp.org/ticket/5716>
CakePHP : The Rapid Development Framework for PHP <https://trac.cakephp.org/>
Cake is a rapid development framework for PHP which uses commonly known design 
patterns like ActiveRecord, Association Data Mapping, Front Controller and MVC. 
Our primary goal is to provide a structured framework that enables PHP users at 
all levels to rapidly develop robust web applications, without any loss to 
flexibility.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"tickets cakephp" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/tickets-cakephp?hl=en
-~----------~----~----~----~------~----~------~--~---

  • [CakePHP : The Rapid Dev... CakePHP : The Rapid Development Framework for PHP

Reply via email to