[Geoserver-users] Creating a new layer in GeoServer from PostGreSQL table.

Hii

I want to add a new feature layer in PostGreSQL from open layers.
I got the answer from openlayers forum as...

http://osgeo-org.1560.x6.nabble.com/creating-a-new-layer-in-database-td5089934.html

Using openlayers directly you can't do this:
You need to call from openlayers some server-side code (i.e. java or
c# or whatever you wanna use) that, in order:
1. enstablish a connection to postgres db
2. launch a series of sql commands that create a table, fields,
indices and so on
3. call the geoserver rest api and configure geoserver accordingly:

I have created table using the c# code.

Now I want to publish a layer in GeoServer using REST API.

I saw the documentation of GEoSever REST API. I could not find anything
which can help me do this. I can see the existing layers, workspaces etc.
but I cannot create any layer.

Any help..

Thanks and Regards
Pankaj Bansal

--
View this message in context: http://osgeo-org.1560.x6.nabble.com/Creating-a-new-layer-in-GeoServer-from-PostGreSQL-table-tp5090539.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

Hi,
for what concerns the GeoServer REST API, you need that after you have completed points 1 and 2.
Here you can find some examples using curl to create all the objects you may need: http://docs.geoserver.org/stable/en/user/rest/examples/curl.html
You can also find examples in some programming languages here: http://docs.geoserver.org/stable/en/user/rest/examples/index.html (not for C# I’m afraid).
What you could need is:

If you are going to use that from c# and you would like to contribute back some examples in that language to enrich the documentation it would be awesome.

Regards,
Mauro

···

2013/11/21 pankaj123 <pankaj.bansal.jiit@anonymised.com>

Hii

I want to add a new feature layer in PostGreSQL from open layers.
I got the answer from openlayers forum as…

http://osgeo-org.1560.x6.nabble.com/creating-a-new-layer-in-database-td5089934.html

Using openlayers directly you can’t do this:
You need to call from openlayers some server-side code (i.e. java or
c# or whatever you wanna use) that, in order:

  1. enstablish a connection to postgres db
  2. launch a series of sql commands that create a table, fields,
    indices and so on
  3. call the geoserver rest api and configure geoserver accordingly:

I have created table using the c# code.

Now I want to publish a layer in GeoServer using REST API.

I saw the documentation of GEoSever REST API. I could not find anything
which can help me do this. I can see the existing layers, workspaces etc.
but I cannot create any layer.

Any help…

Thanks and Regards
Pankaj Bansal


View this message in context: http://osgeo-org.1560.x6.nabble.com/Creating-a-new-layer-in-GeoServer-from-PostGreSQL-table-tp5090539.html
Sent from the GeoServer - User mailing list archive at Nabble.com.


Shape the Mobile Experience: Free Subscription
Software experts and developers: Be at the forefront of tech innovation.
Intel(R) Software Adrenaline delivers strategic insight and game-changing
conversations that shape the rapidly evolving mobile landscape. Sign up now.
http://pubads.g.doubleclick.net/gampad/clk?id=63431311&iu=/4140/ostg.clktrk


Geoserver-users mailing list
Geoserver-users@anonymised.comsts.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users