MIOLO20
Carregando...
Procurando...
Nenhuma entrada encontrada
mschema.class
Ir para a documentação deste ficheiro.
1
<?php
6
class
PostgresSchema
extends
MSchema
7
{
15
function
getTableInfo
($tablename)
16
{
17
//select relfilenode from pg_class where relname = 'pacote';
18
$sql =
new
msql(
"relfilenode"
,
"pg_class"
,
"lower(relname)=?"
);
19
$sql->setParameters( strtolower($tablename) );
20
$q = $this->conn->db->query($sql->select());
21
22
if
($q[0][0])
23
{
24
$sql =
new
mSql(
'attname, atttypid, attinhcount'
,
'pg_attribute'
,
'attrelid=? AND attnum>0 AND atttypid > 0'
,
'attnum'
);
25
$sql->setParameters($q[0][0]);
26
}
27
else
return
null
;
28
29
//select * from pg_attribute where attrelid = 964175 and attnum > 0
30
$query = @$this->conn->getQuery($sql);
31
return
$query->result;
32
}
33
}
34
?>
MSchema
Definição
mschema.class:3
PostgresSchema
Definição
mschema.class:7
PostgresSchema\getTableInfo
getTableInfo($tablename)
Definição
mschema.class:15
classes
database
postgres
mschema.class
Gerado por
1.10.0