mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-31 09:06:17 +00:00
Making DboSybase able to return VIEW's as part of listSources(), making it similar to DboPostgres and DboMysql. Fixes #91
This commit is contained in:
parent
f764c53c55
commit
2c633912e0
1 changed files with 6 additions and 5 deletions
|
@ -143,7 +143,7 @@ class DboSybase extends DboSource {
|
||||||
return $cache;
|
return $cache;
|
||||||
}
|
}
|
||||||
|
|
||||||
$result = $this->_execute("select name from sysobjects where type='U'");
|
$result = $this->_execute("SELECT name FROM sysobjects WHERE type IN ('U', 'V')");
|
||||||
if (!$result) {
|
if (!$result) {
|
||||||
return array();
|
return array();
|
||||||
} else {
|
} else {
|
||||||
|
@ -180,10 +180,11 @@ class DboSybase extends DboSource {
|
||||||
$column[0] = $column[$colKey[0]];
|
$column[0] = $column[$colKey[0]];
|
||||||
}
|
}
|
||||||
if (isset($column[0])) {
|
if (isset($column[0])) {
|
||||||
$fields[$column[0]['Field']] = array('type' => $this->column($column[0]['Type']),
|
$fields[$column[0]['Field']] = array(
|
||||||
'null' => $column[0]['Null'],
|
'type' => $this->column($column[0]['Type']),
|
||||||
'length' => $this->length($column[0]['Type']),
|
'null' => $column[0]['Null'],
|
||||||
);
|
'length' => $this->length($column[0]['Type']),
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue