Postgres::getSchemas PHP Method

getSchemas() public method

Return all schemas in the current database.
public getSchemas ( ) : All
return All schemas, sorted alphabetically
    function getSchemas()
    {
        global $conf;
        if (!$conf['show_system']) {
            $where = "WHERE nspname NOT LIKE 'pg@_%' ESCAPE '@' AND nspname != 'information_schema'";
        } else {
            $where = "WHERE nspname !~ '^pg_t(emp_[0-9]+|oast)\$'";
        }
        $sql = "\n\t\t\tSELECT pn.nspname, pu.rolname AS nspowner,\n\t\t\t\tpg_catalog.obj_description(pn.oid, 'pg_namespace') AS nspcomment\n\t\t\tFROM pg_catalog.pg_namespace pn\n\t\t\t\tLEFT JOIN pg_catalog.pg_roles pu ON (pn.nspowner = pu.oid)\n\t\t\t{$where}\n\t\t\tORDER BY nspname";
        return $this->selectSet($sql);
    }
Postgres