fixed little bugs in firebird import driver
This commit is contained in:
parent
31da317fcc
commit
45fdb318de
@ -53,7 +53,7 @@ class Doctrine_Import_Firebird extends Doctrine_Import
|
|||||||
public function listTableFields($table)
|
public function listTableFields($table)
|
||||||
{
|
{
|
||||||
$table = $this->conn->quote(strtoupper($table), 'text');
|
$table = $this->conn->quote(strtoupper($table), 'text');
|
||||||
$query = 'SELECT RDB\$FIELD_NAME FROM RDB$RELATION_FIELDS WHERE UPPER(RDB$RELATION_NAME) = ' . $table;
|
$query = 'SELECT RDB$FIELD_NAME FROM RDB$RELATION_FIELDS WHERE UPPER(RDB$RELATION_NAME) = ' . $table;
|
||||||
|
|
||||||
return $this->conn->fetchColumn($query);
|
return $this->conn->fetchColumn($query);
|
||||||
}
|
}
|
||||||
@ -85,7 +85,7 @@ class Doctrine_Import_Firebird extends Doctrine_Import
|
|||||||
{
|
{
|
||||||
$query = 'SELECT DISTINCT RDB$VIEW_NAME FROM RDB$VIEW_RELATIONS';
|
$query = 'SELECT DISTINCT RDB$VIEW_NAME FROM RDB$VIEW_RELATIONS';
|
||||||
$table = $this->conn->quote(strtoupper($table), 'text');
|
$table = $this->conn->quote(strtoupper($table), 'text');
|
||||||
$query .= 'WHERE UPPER(RDB\$RELATION_NAME) = ' . $table;
|
$query .= ' WHERE UPPER(RDB$RELATION_NAME) = ' . $table;
|
||||||
|
|
||||||
return $this->conn->fetchColumn($query);
|
return $this->conn->fetchColumn($query);
|
||||||
}
|
}
|
||||||
@ -110,10 +110,7 @@ class Doctrine_Import_Firebird extends Doctrine_Import
|
|||||||
*/
|
*/
|
||||||
public function listTableTriggers($table = null)
|
public function listTableTriggers($table = null)
|
||||||
{
|
{
|
||||||
$query = 'SELECT RDB$TRIGGER_NAME
|
$query = 'SELECT RDB$TRIGGER_NAME FROM RDB$TRIGGERS WHERE RDB$SYSTEM_FLAG IS NULL OR RDB$SYSTEM_FLAG = 0';
|
||||||
FROM RDB$TRIGGERS
|
|
||||||
WHERE RDB$SYSTEM_FLAG IS NULL
|
|
||||||
OR RDB$SYSTEM_FLAG = 0';
|
|
||||||
|
|
||||||
if ( ! is_null($table)) {
|
if ( ! is_null($table)) {
|
||||||
$table = $this->conn->quote(strtoupper($table), 'text');
|
$table = $this->conn->quote(strtoupper($table), 'text');
|
||||||
|
Loading…
x
Reference in New Issue
Block a user