[Geoserver-users] Database queries

Hello All,

I have a number of apps that use a Flash client with Geoserver and
postgres/postgis. Is it possible to use geosever to make queries to the
database outside of the WFS filters? There are a number of tables that I
would like to query in a "non-geographic" way, such as using DISTINCT or
MAX(), etc. Short of writing a java servlet or a cgi (I'm at the "Hello
world" stage as far as java is concerned), is there a way to use geoserver
instead, since the datastores and connections and such are already
configured?

Thanks,
Steve

Stephen Crawford
Center for Environmental Informatics
GeoVISTA Center
The Pennsylvania State University
814.865.9905
src176@anonymised.com

Unfortunately no, not at this time. Andrea and I were just talking about this a bit today. The WPS offers one potential route to expose functionality like this. But yeah, at the time you're probably best off just hacking it in whatever way you know best...

Though actually, for something like 'MAX()' you can use a function. There's a good bit of functionality in the functions (they're expressions you can use in filters). Though at the moment I don't think any of these get passed to the database, they're just computed in java.

best regards,

Chris

Stephen Crawford wrote:

Hello All,

I have a number of apps that use a Flash client with Geoserver and
postgres/postgis. Is it possible to use geosever to make queries to the
database outside of the WFS filters? There are a number of tables that I
would like to query in a "non-geographic" way, such as using DISTINCT or
MAX(), etc. Short of writing a java servlet or a cgi (I'm at the "Hello
world" stage as far as java is concerned), is there a way to use geoserver
instead, since the datastores and connections and such are already
configured?

Thanks,
Steve

Stephen Crawford
Center for Environmental Informatics
GeoVISTA Center
The Pennsylvania State University
814.865.9905
src176@anonymised.com

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

!DSPAM:1003,45a2ea23234271995013331!

--
Chris Holmes
The Open Planning Project
http://topp.openplans.org

Chris Holmes ha scritto:

Unfortunately no, not at this time. Andrea and I were just talking about this a bit today. The WPS offers one potential route to expose functionality like this. But yeah, at the time you're probably best off just hacking it in whatever way you know best...

Though actually, for something like 'MAX()' you can use a function. There's a good bit of functionality in the functions (they're expressions you can use in filters). Though at the moment I don't think any of these get passed to the database, they're just computed in java.

As far as I know, you can't use functions in the select list, plus max()
is an aggregate one, our functions do only work for single record.
It would be indeed nice to extend the Geoserver queries to allow for
aggregation and joins, that is, have a filter language that exposes
the same power as SQL. Something for the future I guess, it requires
extensive changes to the gt2 datastores.

Cheers
Andrea