Commit 387f615ff58a879334e7f4385083d7afb2d41416
1 parent
bbe45b61
Exists in
master
and in
7 other branches
Correção na montagem do sql saiku para inclusão de filtro
Showing
2 changed files
with
4 additions
and
0 deletions
Show diff stats
admin/admin.db
No preview for this file type
ferramentas/saiku/esquemaxml.php
... | ... | @@ -657,6 +657,10 @@ function dimensoesTabelas(){ |
657 | 657 | ON tabela{$r["codigo_tipo_regiao"]}.{$r["identificador"]}::text = tabelamedida{$c["id_medida_variavel"]}.{$c["colunaidgeo"]}::text |
658 | 658 | "; |
659 | 659 | $sql .= $dimRegioes[$c["codigo_tipo_regiao"]]["juncoes"]; |
660 | + | |
661 | + if($c["filtro"] != ""){ | |
662 | + $sql .= " WHERE ".str_replace('"',"'",$c["filtro"]); | |
663 | + } | |
660 | 664 | |
661 | 665 | $xml .= " |
662 | 666 | <view alias='view_{$c["esquemadb"]}{$c["tabela"]}' ><SQL dialect='generic' >$sql</SQL></view> | ... | ... |