[Geoserver-users] GeoServer 2.1beta1 SQL View Errors on edit NPE
Hi all, i created this sql view layer and it worked fine in preview SELECT st_union(the_geom), file_name FROM district_borough_unitary_region group by file_name Now I want to modify it to this SELECT ST_Multi(ST_Union(the_geom)), file_name FROM district_borough_unitary_region group by file_name But its throwing execptions with this stacktrace, [Notce the NPE as the cause] org.apache.wicket.WicketRuntimeException: Error attaching this container for rendering: [MarkupContainer [Component id = attributePanel]] at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1602) at org.apache.wicket.Component.onBeforeRender(Component.java:3727) at org.apache.wicket.Component.internalBeforeRender(Component.java:1009) at org.apache.wicket.Component.beforeRender(Component.java:1041) at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1590) at org.apache.wicket.Component.onBeforeRender(Component.java:3727) at org.apache.wicket.Component.internalBeforeRender(Component.java:1009) at org.apache.wicket.Component.beforeRender(Component.java:1041) at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1590) at org.apache.wicket.Component.onBeforeRender(Component.java:3727) at org.apache.wicket.Component.internalBeforeRender(Component.java:1009) at org.apache.wicket.Component.beforeRender(Component.java:1041) at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1590) at org.apache.wicket.Component.onBeforeRender(Component.java:3727) at org.apache.wicket.markup.repeater.AbstractRepeater.onBeforeRender(AbstractRepeater.java:147) at org.apache.wicket.Component.internalBeforeRender(Component.java:1009) at org.apache.wicket.Component.beforeRender(Component.java:1041) at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1590) at org.apache.wicket.Component.onBeforeRender(Component.java:3727) at org.apache.wicket.Component.internalBeforeRender(Component.java:1009) at org.apache.wicket.Component.beforeRender(Component.java:1041) at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1590) at org.apache.wicket.Component.onBeforeRender(Component.java:3727) at org.apache.wicket.extensions.markup.html.tabs.TabbedPanel.onBeforeRender(TabbedPanel.java:205) at org.apache.wicket.Component.internalBeforeRender(Component.java:1009) at org.apache.wicket.Component.beforeRender(Component.java:1041) at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1590) at org.apache.wicket.Component.onBeforeRender(Component.java:3727) at org.apache.wicket.Component.internalBeforeRender(Component.java:1009) at org.apache.wicket.Component.beforeRender(Component.java:1041) at org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1590) at org.apache.wicket.Component.onBeforeRender(Component.java:3727) at org.apache.wicket.Page.onBeforeRender(Page.java:1458) at org.apache.wicket.Component.internalBeforeRender(Component.java:1009) at org.apache.wicket.Component.beforeRender(Component.java:1041) at org.apache.wicket.Component.prepareForRender(Component.java:2167) at org.apache.wicket.Page.renderPage(Page.java:892) at org.apache.wicket.protocol.http.WebRequestCycle.redirectTo(WebRequestCycle.java:163) at org.apache.wicket.request.target.component.PageRequestTarget.respond(PageRequestTarget.java:58) at org.apache.wicket.request.AbstractRequestCycleProcessor.respond(AbstractRequestCycleProcessor.java:104) at org.apache.wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:1245) at org.apache.wicket.RequestCycle.step(RequestCycle.java:1316) at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1418) at org.apache.wicket.RequestCycle.request(RequestCycle.java:532) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:356) at org.apache.wicket.protocol.http.WicketServlet.doPost(WicketServlet.java:145) at javax.servlet.http.HttpServlet.service(HttpServlet.java:637) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.springframework.web.servlet.mvc.ServletWrappingController.handleRequestInternal(ServletWrappingController.java:158) at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153) at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:48) at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:875) at
Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view
That was spot on. Thank you very much. I now want to use aparameterized query like this SELECT "Regions"."gid" as rgid, "Regions"."name" as rname, district_borough_unitary_region.gid, district_borough_unitary_region."name", district_borough_unitary_region.area_code, district_borough_unitary_region.descriptio, district_borough_unitary_region.file_name, district_borough_unitary_region."number", district_borough_unitary_region.number0, district_borough_unitary_region.unit_id, district_borough_unitary_region.polygon_id, district_borough_unitary_region.code, district_borough_unitary_region.hectares, district_borough_unitary_region.area, district_borough_unitary_region.type_code, district_borough_unitary_region.descript0, district_borough_unitary_region.type_cod0, district_borough_unitary_region.descript1, district_borough_unitary_region.the_geom FROM public."Regions" INNER JOIN public.district_borough_unitary_region ON ST_Intersects("Regions".the_geom,district_borough_unitary_region.the_geom) where "Regions"."gid" = %grid% But am getting an error Failed to create SQL view: ERROR: syntax error at or near ")" Position: 1019 Is this how to use the parameterized view or am doing something wrong? Regards farouk A --- On Thu, 9/9/10, Justin Deoliveira wrote: From: Justin Deoliveira Subject: Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: "farouk alhassan" Cc: geoserver-users@lists.sourceforge.net Date: Thursday, 9 September, 2010, 10:06 Hi Farouk, I think you just have to remove the ";" after the statement. -Justin On Thu, Sep 9, 2010 at 8:44 AM, farouk alhassan wrote: Hi, I am trying to enter the following sql into the new SQL View Editor. SELECT "Regions"."gid" as rgid, "Regions"."name" as rname, district_borough_unitary_region.gid, district_borough_unitary_region."name", district_borough_unitary_region.area_code, district_borough_unitary_region.descriptio, district_borough_unitary_region.file_name, district_borough_unitary_region."number", district_borough_unitary_region.number0, district_borough_unitary_region.unit_id, district_borough_unitary_region.polygon_id, district_borough_unitary_region.code, district_borough_unitary_region.hectares, district_borough_unitary_region.area, district_borough_unitary_region.type_code, district_borough_unitary_region.descript0, district_borough_unitary_region.type_cod0, district_borough_unitary_region.descript1, district_borough_unitary_region.the_geom FROM public."Regions" INNER JOIN public.district_borough_unitary_region ON ST_Intersects("Regions".the_geom,district_borough_unitary_region.the_geom) where "Regions"."gid" = 1; When I run it I get this error Failed to create SQL view: ERROR: syntax error at or near ";" Position: 1027 but the same sql works perfectly well in pgAdmin III. Getting rid of the where clause fixes the problem but I really need to filter the results since the dataset is too large. Any Ideas what I may be doing wrong? Thanks Farouk A --- On Thu, 9/9/10, farouk alhassan wrote: From: farouk alhassan Subject: Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: geoserver-users@lists.sourceforge.net Date: Thursday, 9 September, 2010, 4:16 Hi Justin, Thanks for the tip. I deleted my whole tomcat installation and installed a new version and deployed new version of the geoserver war file and the links now appear. May have been caused by traces of my previous geoserver war still being held on to by tomcat. Thanks for the help. Very much appreciated Regards Farouk A --- On Wed, 8/9/10, Justin Deoliveira wrote: From: Justin Deoliveira Subject: Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: geoserver-users@lists.sourceforge.net Date: Wednesday, 8 September, 2010, 23:41 Hi Farouk, It is appreciated if you can keep all correspondance on the public list. Thanks. So this seems strange. If you have a postgis store setup and are not seeing the links when you add a new layer it leads me to believe there is an issue with the installation. Perhaps some old versions of the geoserver jars around. Can you navigate to the WEB-INF/lib directory of the geoserver installation and verify that only 2.1-beta jars are present. What type of setup are you running? Windows installer? platform independent binary? On Wed, Sep 8, 2010 at 7:55 PM, farouk alhassan wrote: Hi I'm trying with PostGIS. Regards Farouk A --- On Wed, 8/9/10, Justin Deoliveira wrote: From: Justin Deoliveira Subject: Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: "fa
Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view
Hi, I am trying to enter the following sql into the new SQL View Editor. SELECT "Regions"."gid" as rgid, "Regions"."name" as rname, district_borough_unitary_region.gid, district_borough_unitary_region."name", district_borough_unitary_region.area_code, district_borough_unitary_region.descriptio, district_borough_unitary_region.file_name, district_borough_unitary_region."number", district_borough_unitary_region.number0, district_borough_unitary_region.unit_id, district_borough_unitary_region.polygon_id, district_borough_unitary_region.code, district_borough_unitary_region.hectares, district_borough_unitary_region.area, district_borough_unitary_region.type_code, district_borough_unitary_region.descript0, district_borough_unitary_region.type_cod0, district_borough_unitary_region.descript1, district_borough_unitary_region.the_geom FROM public."Regions" INNER JOIN public.district_borough_unitary_region ON ST_Intersects("Regions".the_geom,district_borough_unitary_region.the_geom) where "Regions"."gid" = 1; When I run it I get this error Failed to create SQL view: ERROR: syntax error at or near ";" Position: 1027 but the same sql works perfectly well in pgAdmin III. Getting rid of the where clause fixes the problem but I really need to filter the results since the dataset is too large. Any Ideas what I may be doing wrong? Thanks Farouk A --- On Thu, 9/9/10, farouk alhassan wrote: From: farouk alhassan Subject: Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: geoserver-users@lists.sourceforge.net Date: Thursday, 9 September, 2010, 4:16 Hi Justin, Thanks for the tip. I deleted my whole tomcat installation and installed a new version and deployed new version of the geoserver war file and the links now appear. May have been caused by traces of my previous geoserver war still being held on to by tomcat. Thanks for the help. Very much appreciated Regards Farouk A --- On Wed, 8/9/10, Justin Deoliveira wrote: From: Justin Deoliveira Subject: Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: geoserver-users@lists.sourceforge.net Date: Wednesday, 8 September, 2010, 23:41 Hi Farouk, It is appreciated if you can keep all correspondance on the public list. Thanks. So this seems strange. If you have a postgis store setup and are not seeing the links when you add a new layer it leads me to believe there is an issue with the installation. Perhaps some old versions of the geoserver jars around. Can you navigate to the WEB-INF/lib directory of the geoserver installation and verify that only 2.1-beta jars are present. What type of setup are you running? Windows installer? platform independent binary? On Wed, Sep 8, 2010 at 7:55 PM, farouk alhassan wrote: Hi I'm trying with PostGIS. Regards Farouk A --- On Wed, 8/9/10, Justin Deoliveira wrote: From: Justin Deoliveira Subject: Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: "farouk alhassan" Cc: geoserver-users@lists.sourceforge.net Date: Wednesday, 8 September, 2010, 9:31 Hi Farouk, Are you trying with arcsde? Or another database? On Wed, Sep 8, 2010 at 7:06 AM, farouk alhassan wrote: Hi I am also trying to do the same thing but could not find any of the links mentioned in the article. I'm using this document as a guide http://gridlock.openplans.org/geoserver/trunk/doc/en/user/data/sqlview.html Let me know if you make any progress on it. Regards Farouk A --- On Wed, 8/9/10, sonya.dow...@dpipwe.tas.gov.au wrote: From: sonya.dow...@dpipwe.tas.gov.au Subject: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: geoserver-users@lists.sourceforge.net Date: Wednesday, 8 September, 2010, 3:16 Hi All, I have installed GeoServer 2.1-beta1 onto my local PC to try out the new SQL views. When I go to add new ArcSDE layers, at the bottom of the page I have the option to create new feature type, but there is nothing to allow me to configure a new SQL view. Is there something I missed when installing, or is this option only available to some databases? Cheers, Sonya -Inline Attachment Follows- -- This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd -Inline Attachment Follows- ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users -- This SF.net Dev2Dev email is sponsored by:
Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view
Hi Justin, Thanks for the tip. I deleted my whole tomcat installation and installed a new version and deployed new version of the geoserver war file and the links now appear. May have been caused by traces of my previous geoserver war still being held on to by tomcat. Thanks for the help. Very much appreciated Regards Farouk A --- On Wed, 8/9/10, Justin Deoliveira wrote: From: Justin Deoliveira Subject: Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: geoserver-users@lists.sourceforge.net Date: Wednesday, 8 September, 2010, 23:41 Hi Farouk, It is appreciated if you can keep all correspondance on the public list. Thanks. So this seems strange. If you have a postgis store setup and are not seeing the links when you add a new layer it leads me to believe there is an issue with the installation. Perhaps some old versions of the geoserver jars around. Can you navigate to the WEB-INF/lib directory of the geoserver installation and verify that only 2.1-beta jars are present. What type of setup are you running? Windows installer? platform independent binary? On Wed, Sep 8, 2010 at 7:55 PM, farouk alhassan wrote: Hi I'm trying with PostGIS. Regards Farouk A --- On Wed, 8/9/10, Justin Deoliveira wrote: From: Justin Deoliveira Subject: Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: "farouk alhassan" Cc: geoserver-users@lists.sourceforge.net Date: Wednesday, 8 September, 2010, 9:31 Hi Farouk, Are you trying with arcsde? Or another database? On Wed, Sep 8, 2010 at 7:06 AM, farouk alhassan wrote: Hi I am also trying to do the same thing but could not find any of the links mentioned in the article. I'm using this document as a guide http://gridlock.openplans.org/geoserver/trunk/doc/en/user/data/sqlview.html Let me know if you make any progress on it. Regards Farouk A --- On Wed, 8/9/10, sonya.dow...@dpipwe.tas.gov.au wrote: From: sonya.dow...@dpipwe.tas.gov.au Subject: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: geoserver-users@lists.sourceforge.net Date: Wednesday, 8 September, 2010, 3:16 Hi All, I have installed GeoServer 2.1-beta1 onto my local PC to try out the new SQL views. When I go to add new ArcSDE layers, at the bottom of the page I have the option to create new feature type, but there is nothing to allow me to configure a new SQL view. Is there something I missed when installing, or is this option only available to some databases? Cheers, Sonya -Inline Attachment Follows- -- This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd -Inline Attachment Follows- ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users -- This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users -- Justin DeoliveiraOpenGeo - http://opengeo.org Enterprise support for open source geospatial. -- Justin DeoliveiraOpenGeo - http://opengeo.org Enterprise support for open source geospatial. -Inline Attachment Follows- -- This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd -Inline Attachment Follows- ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users -- This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
Re: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view
Hi I am also trying to do the same thing but could not find any of the links mentioned in the article. I'm using this document as a guide http://gridlock.openplans.org/geoserver/trunk/doc/en/user/data/sqlview.html Let me know if you make any progress on it. Regards Farouk A --- On Wed, 8/9/10, sonya.dow...@dpipwe.tas.gov.au wrote: From: sonya.dow...@dpipwe.tas.gov.au Subject: [Geoserver-users] GeoServer 2.1beta1: unable to configure a new SQL view To: geoserver-users@lists.sourceforge.net Date: Wednesday, 8 September, 2010, 3:16 Hi All, I have installed GeoServer 2.1-beta1 onto my local PC to try out the new SQL views. When I go to add new ArcSDE layers, at the bottom of the page I have the option to create new feature type, but there is nothing to allow me to configure a new SQL view. Is there something I missed when installing, or is this option only available to some databases? Cheers, Sonya -Inline Attachment Follows- -- This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd -Inline Attachment Follows- ___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users -- This SF.net Dev2Dev email is sponsored by: Show off your parallel programming skills. Enter the Intel(R) Threading Challenge 2010. http://p.sf.net/sfu/intel-thread-sfd___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users
[Geoserver-users] Getting Started with Layers
Hi All, I am new to the world of GIS and Geoserver. I have read this tutorial http://geoserver.org/display/GEOSDOC/Google+Maps And it was very good. I went ahead and read this http://copperinteractive.net/geoserver/trunk/doc/en/user/gettingstarted/shapefile-quickstart/index.html And now I want to use my new york layer (nyc_roads:nyc_roads) in the Google Maps but its not working. I changed the layers line to this layers: 'nyc_roads:nyc_roads' but nothing appears on the map. If someone can show me how to use my layer, I will be very much grateful. Regards Farouk A -- Sell apps to millions through the Intel(R) Atom(Tm) Developer Program Be part of this innovative community and reach millions of netbook users worldwide. Take advantage of special opportunities to increase revenue and speed time-to-market. Join now, and jumpstart your future. http://p.sf.net/sfu/intel-atom-d2d___ Geoserver-users mailing list Geoserver-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geoserver-users