[Chameleon] SQlQuery Widget

Yewondwossen Assefa assefa at dmsolutions.ca
Fri Feb 24 14:24:17 EST 2006


Hi There,

  I think It might be a problem connecting to your postgres/postgis 
database.  Here are 2 possiblites :

   - you did not load the postgis module in your setup (the name of the 
module is pg_pgslq.dll). You need to load the module using 
dl("php_pgsql.dll") or in your php.ini

   - Or the connection elements that you gave are not "correct".

  Here is how you can debug :

   - open the sqlquery widget (function ParseURL).  You will see 
soethinh that looks like
     ...
     break;
   case "PGSQL":
   ....

    $link = @pg_connect($szConnect);

  remove the @ at the begging of the line :
      $link = pg_connect($szConnect);

  This will probably let you know what the problem is.

Hope it helps.

later,


listserver server wrote:
> I'm tryng to use SqlQuerywidget with Postgis database, but i've some 
> problems!
> 
> i've added this in my html page
> 
> <cwc2 type="SharedResource" name="postresource">
>     <POINTS Name="SearchResults" SRName="postresource" 
> SRLATCOL="f_latitude" SRLONCOL="f_longitude" siteName="f_csinitname" />
> </cwc2>
> 
> 
> and this
> 
> <CWC2 TYPE="SQLQuery" VISIBLE="TRUE" ENABLED="TRUE" SQLQUERY="SELECT 
> random();" SERVER="localhost" DATABASE="name of Database"
> USERNAME="my_user" PASSWORD="my_pass" DBTYPE="PGSQL" 
> SHAREDRESOURCENAME="postresourc
> e" SAVEQUERY="TRUE"/> </CWC2>
> 
> 
> My application doesn't work and i've only a white page!
> 
> 
> if i remove <CWC2 TYPE="SQLQuery" VISIBLE="TRUE" ENABLED="TRUE" 
> SQLQUERY="SELECT random();" SERVER="localhost" DATABASE="name of Database"
> USERNAME="my_user" PASSWORD="my_pass" DBTYPE="PGSQL" 
> SHAREDRESOURCENAME="postresource" SAVEQUERY="TRUE"/> </CWC2>
> 
> all is fine!
> 
> what is wrong??
> 
> Thanks in advance
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Chameleon mailing list
> Chameleon at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/chameleon


-- 
----------------------------------------------------------------
Assefa Yewondwossen
Software Analyst

Email: assefa at dmsolutions.ca
http://www.dmsolutions.ca/

Phone: (613) 565-5056 (ext 14)
Fax:   (613) 565-0925
----------------------------------------------------------------




More information about the Chameleon mailing list