Merge branch 'master' of github.com:aviat4ion/OpenSQLManager
This commit is contained in:
commit
103d665e57
@ -24,6 +24,9 @@ class ODBC extends DB_PDO {
|
|||||||
function __construct($dsn, $username=null, $password=null, $options=array())
|
function __construct($dsn, $username=null, $password=null, $options=array())
|
||||||
{
|
{
|
||||||
parent::__construct("odbc:$dsn", $username, $password, $options);
|
parent::__construct("odbc:$dsn", $username, $password, $options);
|
||||||
|
|
||||||
|
$class = __CLASS__.'_manip';
|
||||||
|
$this->manip = new $class;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -108,10 +108,19 @@ class pgSQL extends DB_PDO {
|
|||||||
*/
|
*/
|
||||||
function get_schemas($database="")
|
function get_schemas($database="")
|
||||||
{
|
{
|
||||||
$sql = 'SELECT ';
|
if($database === "")
|
||||||
|
{
|
||||||
|
$sql = 'SELECT DISTINCT "schemaname" FROM pg_tables
|
||||||
|
WHERE "schemaname" NOT LIKE \'pg\_%\'';
|
||||||
|
}
|
||||||
|
|
||||||
|
$sql = 'SELECT DISTINCT "schemaname" FROM pg_tables
|
||||||
|
WHERE "schemaname" NOT LIKE \'pg\_%\'';
|
||||||
|
|
||||||
$res = $this->query($sql);
|
$res = $this->query($sql);
|
||||||
$schemas = $res->fetchAll(PDO::FETCH_ASSOC);
|
$schemas = $res->fetchAll(PDO::FETCH_ASSOC);
|
||||||
|
|
||||||
|
return $schemas;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Reference in New Issue
Block a user