Olá
Estou a utilizar a variavel : $postgis_mapa = "..." com a conexão ao POSTGIS e desta forma quando utilizo o menu Opções;Tabela;Relatórios, obtenho o erro:
Parse error: syntax error, unexpected T_STRING in C:\ms4w\Apache\htdocs\i3geo\ferramentas\tabela\relatorio.php(8) : eval()'d code on line 1
Warning: [MapServer Error]: msQueryByRect(): No matching record(s) found. in C:\ms4w\Apache\htdocs\i3geo\ferramentas\tabela\relatorio.php on line 39
Warning: [MapServer Error]: msPOSTGISLayerOpen(): Couldn't make connection to DB with connect string ' '. Error reported was 'fe_sendauth: no password supplied '. This error occured when trying to make a connection to the specified postgresql server. Most commonly this is caused by (1) incorrect connection string (2) you didnt specify a 'user=...' in your connection string (3) the postmaster (postgresql server) isnt running (4) you are not allowing TCP/IP connection to the postmaster (5) your postmaster is not running on the correct port - if its not on 5432 you must specify a 'port=...' (6) the security on your system does not allow the webserver (usually user 'nobody') to make socket connections to the postmaster (7) you forgot to specify a 'host=...' if the postmaster is on a different machine (8) you made a typo in C:\ms4w\Apache\htdocs\i3geo\ferramentas\tabela\relatorio.php on line 40
Warning: [MapServer Error]: msQueryByRect(): No matching record(s) found. in C:\ms4w\Apache\htdocs\i3geo\ferramentas\tabela\relatorio.php on line 40
Serei então obrigado a colocar a string de ligação em cada MAPFILE?
Cumprimentos a todos
Stelmo
Autor: stelmo barbosa

66 comentários
?
CONNECTION "ligacao" obtive o seguinte erro: Warning: [MapServer Error]: msQueryByRect(): No matching record(s) found. in C:\ms4w\Apache\htdocs\i3geo\ferramentas\tabela\relatorio.php on line 43 Warning: Invalid argument supplied for foreach() in C:\ms4w\Apache\htdocs\i3geo\ferramentas\tabela\relatorio.php on line 115 2º Cenario: na layer coloquei: LAYER
CONNECTION "host=server user=user password=pass dbname=postgis port=5432" mas obtive o mesmo erro. Cumprimentos Stelmo
projecao do mapa? edmar.moretti@terra.com.br Skype: edmar.moretti Blog: edmarmoretti.blogspot.com/ Ohloh: www.ohloh.net/accounts/edmarmoretti stelmo@sapo.pt escreveu:
> Forum: Geral - usuários e desenvolvedores
>
> Thread: Erro no Menu - Opções;Tabela;Relatórios
>
> Author: stelmo barbosa
> Posted: 2009-10-06 08:44:13.561645-03
>
> Testei este novo ficheiro com dois cenários:
>
> 1º Coloquei $postgis_mapa = array("ligacao"=>"host=.....
>
> e na layer coloquei:
>
> LAYER
> CONNECTION "ligacao"
>
> obtive o seguinte erro:
>
> *Warning*: [MapServer Error]: msQueryByRect(): No matching record(s)
> found. in
> *C:\ms4w\Apache\htdocs\i3geo\ferramentas\tabela\relatorio.php* on line
> *43*
>
> *Warning*: Invalid argument supplied for foreach() in
> *C:\ms4w\Apache\htdocs\i3geo\ferramentas\tabela\relatorio.php* on line
> *115*
>
> 2º Cenario:
>
> na layer coloquei:
>
> LAYER
> CONNECTION "host=server user=user password=pass dbname=postgis
> port=5432"
>
> mas obtive o mesmo erro.
>
> Cumprimentos
>
> Stelmo
>
> Recebendo correspondência demais? Gerencie suas notificações em:
> www.softwarepublico.gov.br/notifications/manage
>
"conexao1"=>"user=geodados password=geodados dbname=geodados host=10.1.1.36 port=5432",
"conexao2"=>"user=geodados password=geodados dbname=geo host=10.1.1.36 port=5432"
) Nesse caso, no mapfile, é necessário incluir em CONNECTION a chave do array, por exemplo, CONNECTION "conexao1" Para efeitos de compatibilidade, a forma anterior ainda é possível, mas pelo que foi relatado, a opção de relatório não manteve a compatibilidade com a forma antiga.