[postgis-users] How to remotely edit a postgis db?
Hi, with Quantum GIS v1.6.0 I just managed to connect and edit!!! I don´t believe i because I was trying all last night and it wasn´t working? ok...so it works! great! As a newbie then, I have a questions? How do I define different users to different tables in a database?...I was thinking of creating various databases for different users. Could I then define different user accounts/roles to the databases to ensure that only correct person is able to edit his/her database?...for example I have a region with 10 counties. If I create 10 databases for each county, I could then assign 10 users (county_1, county_2 ...county_10) to database_1, Database_2...Database_10 etc so that the user "County_2" can only edit the database "County_2". does that make sense? Is it feasable/doable? yours, Robert ___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users
Re: [postgis-users] How to remotely edit a postgis db?
El Wednesday 26 January 2011, Robert Buckley escribió: > Hi, > > i have installed postgis on postgresql and everything seems to working > fine. At the moment I uploading tables through shp2psql and this is > working too. > > I would now like to edit the data from remote pcs. I have experience using > various open source gis software e.g Jump, QGIS, svSIG, Udig etc but I > cannot edit and commit changed through these gis systems. > > My system is Ubuntu 8.04. > postgresql is version 8.3 / postgresql-8.3-postgis > > I installed postgis as sudo...therefore the installation folder is owned by > root > > cd .. /usr/share/postgresql > drwxr-xr-x 6 root root 4096 2011-01-25 15:22 8.3 > > I have created a user called geoserver for gis work > > sudo -u postgres -i > createuser geoserver > createdb -E UTF8 -O geoserver gis > > > and then created the language... > > createlang plpgsql gis > > > I was following these instructions by the way. > http://weait.com/content/build-your-own-openstreetmap-server-v1 > > > So...as far as I can see, I have a working installation of postgresql with > postgis isntalled. I can log in to postgresql with pgadmin3 and see my gis > db which is spatially enabled with the postgis functions. Fantastic! > > I uploaded a shp and even loaded it into geoserver which displayed it > perfectly. > > so...Now I want to edit the data... It is probably a problem of postgreSQL configuration, not PostGIS. Check which users (postgreSQL users) have rights to select, update and delete the tables you are trying to use. > > Question: > 1. does user geoserver have editing permission? How can I find out? Try to connect to the database with the same user and password geoserver is using from the IP in which geoserver is installed. If you can, geoserver can. > 2. is postgres a user account on ubuntu or just the login name for the > db?...When I look in my /home folder on ubuntu there is no folder there > called postgres so I guess no!?!? postgres is a user account on your OS, but is also a user account for postgreSQL, which is a completely different thing. > 3. Why can´t I just log in through any of the software mentioned above and > edit? Have you checked that the /etc/postgresql/*/main/pg_hba.conf file is configured for the username, password and IP you are trying to use? Have you checked that the /etc/postgresql/*/main/postgresql.conf file is configured for the IP you are trying to use? The "#listen_addresses = 'localhost'" line. > > > > I would be grateful for any pointers... > > thanks, > > Robert Buckley -- María Arias de Reyna Domínguez Área de Operaciones Emergya Consultoría Tfno: +34 954 51 75 77 / +34 607 43 74 27 Fax: +34 954 51 64 73 www.emergya.es ___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users
[postgis-users] How to remotely edit a postgis db?
Hi, i have installed postgis on postgresql and everything seems to working fine. At the moment I uploading tables through shp2psql and this is working too. I would now like to edit the data from remote pcs. I have experience using various open source gis software e.g Jump, QGIS, svSIG, Udig etc but I cannot edit and commit changed through these gis systems. My system is Ubuntu 8.04. postgresql is version 8.3 / postgresql-8.3-postgis I installed postgis as sudo...therefore the installation folder is owned by root cd .. /usr/share/postgresql drwxr-xr-x 6 root root 4096 2011-01-25 15:22 8.3 I have created a user called geoserver for gis work sudo -u postgres -i createuser geoserver createdb -E UTF8 -O geoserver gis and then created the language... createlang plpgsql gis I was following these instructions by the way. http://weait.com/content/build-your-own-openstreetmap-server-v1 So...as far as I can see, I have a working installation of postgresql with postgis isntalled. I can log in to postgresql with pgadmin3 and see my gis db which is spatially enabled with the postgis functions. Fantastic! I uploaded a shp and even loaded it into geoserver which displayed it perfectly. so...Now I want to edit the data... Question: 1. does user geoserver have editing permission? How can I find out? 2. is postgres a user account on ubuntu or just the login name for the db?...When I look in my /home folder on ubuntu there is no folder there called postgres so I guess no!?!? 3. Why can´t I just log in through any of the software mentioned above and edit? I would be grateful for any pointers... thanks, Robert Buckley ___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users
Re: [postgis-users] Strange behavior with a polygon and line that claim to intersect ....
Well, I looked at it in QGIS and the line seems to cross the border of the polygon. I have attached the part of the polygon where it crosses, with the line in violet and the intersecting part in green. /Nicklas On Tue, 2011-01-25 at 15:00 -0500, Bryan Montgomery wrote: > Hello, > Is there a way to debug a problem I have with a polygon and line? I > was running a query that used st_intersects and st_intersection to get > the length of lines that are within the polygon. I was spot checking > some of the data and came up with a particularly strange example. > > Visually, the polygon looks as it should, the line clearly appears to > be completely contained within the polygon however st_crosses returns > true and intersection returns a subset of the line. I've tried this on > postgis version 1.3 and 1.4 and both behave the same. I'm inclined to > believe there is a stray point but given the polygon 2,700+ points I'm > not sure how I find it! I suppose it's possible that there is a bug - > or maybe I'm just completely missing something. > > I tried finding the closest point on the polygon to the line - but > when I tried to find a way to do this it seemed that the suggestions > were for finding the closest point when the other point was outside > the polygon? > > Appreciate any help, > > Thanks - Bryan. > ___ > postgis-users mailing list > postgis-users@postgis.refractions.net > http://postgis.refractions.net/mailman/listinfo/postgis-users <>___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users
Re: [postgis-users] WKTRaster problems on Mac
Ken, If it helps -- here is a quick tutorial we wrote a while ago that shows how to use the theming feature. It's a bit dated, but I think still relevant. http://www.postgresonline.com/journal/archives/72-OpenJump-for-PostGIS-Spati al-Ad-Hoc-Queries.html Hope that helps, Leo and Regina http://www.postgis.us -Original Message- From: postgis-users-boun...@postgis.refractions.net [mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of knussear Sent: Tuesday, January 25, 2011 2:19 PM To: postgis-users@postgis.refractions.net Subject: Re: [postgis-users] WKTRaster problems on Mac I'm not an open Jump user, so I haven't explored any of these options Paragon Corporation-2 wrote: > > Ken, > > Did you use the theming features of OpenJump. That is what we usually > use to see the output. > > Here is a snapshot from the latest revision of our raster chapter of > our upcoming book (due out hopefully in Mid-late February in print). > Which is the output of this query (a raster intersected with a 100 > meter radius buffer) after we apply a gradient theme. > > SELECT CAST((gval).val As integer) AS val, > ST_AsBinary((gval).geom) As geom > FROM ( > SELECT ST_Intersection(rast,1,buf.geom) As gval > FROM ch13.kauai > INNER JOIN ( > SELECT ST_Buffer( > ST_GeomFromText('POINT(444205 2438785)',26904),100) > As geom) As buf ON > ST_Intersects(rast,buf.geom)) As foo > > Also BTW: Didn't see an image attached to your email. > > Also I recall OJ has some issues with double precision and long int > which is why we cast it to an integer > > Hope that helps, > Regina and Leo > http://www.postgis.us > > > > > > > > -Original Message- > From: postgis-users-boun...@postgis.refractions.net > [mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of > knussear > Sent: Tuesday, January 25, 2011 7:58 AM > To: postgis-users@postgis.refractions.net > Subject: Re: [postgis-users] WKTRaster problems on Mac > > > I did finally get the Open Jump call to work, and can see the polygon > output. However its not entirely useful as I intend to use map algebra > etc on the raster.. > > The attachment from qgis shows the original input raster on top of > what qgis shows for the raster. The qgis image of the postgis raster > alone is just all green (gray etc). > > Ken > > > Pierre Racine-2 wrote: >> >> Actually the image in the previous post is the original. Attached is >> what he sees when viewing the image in QGIS after it was imported in >> PostGIS raster... >> >>>-Original Message- >>>From: postgis-users-boun...@postgis.refractions.net >>>[mailto:postgis-users- boun...@postgis.refractions.net] On Behalf Of >>>Pierre Racine >>>Sent: 24 janvier 2011 16:45 >>>To: PostGIS Users Discussion >>>Subject: Re: [postgis-users] WKTRaster problems on Mac >>> >>>No but his first attempt was to open the image in QGIS. See the first > mail. I attach the image he sent >>>me as it was not attached in the first mail sent to users-postgis. >>> >>>I think this is typical of the first problem you met with the driver. >>> >>>Pierre >>> The GDAL driver is not being used in the commands I've seen. Did you execute the query Pierre suggested? SELECT ST_AsBinary((gv).geom), (gv).val FROM (SELECT ST_DumpAsPolygons(rast) gv FROM x01) foo Replacing "x01" by your table's name. -- Jorge Arévalo Internet & Mobilty Division, DEIMOS jorge.arev...@deimos-space.com http://mobility.grupodeimos.com/ http://gis4free.wordpress.com http://geohash.org/ezjqgrgzz0g ___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users >> >> >> ___ >> postgis-users mailing list >> postgis-users@postgis.refractions.net >> http://postgis.refractions.net/mailman/listinfo/postgis-users >> >> > > -- > View this message in context: > http://old.nabble.com/WKTRaster-problems-on-Mac-tp30721572p30755095.ht > ml Sent from the PostGIS - User mailing list archive at Nabble.com. > > ___ > postgis-users mailing list > postgis-users@postgis.refractions.net > http://postgis.refractions.net/mailman/listinfo/postgis-users > > > ___ > postgis-users mailing list > postgis-users@postgis.refractions.net > http://postgis.refractions.net/mailman/listinfo/postgis-users > > -- View this message in context: http://old.nabble.com/WKTRaster-pro
Re: [postgis-users] WKTRaster problems on Mac
I'm not an open Jump user, so I haven't explored any of these options Paragon Corporation-2 wrote: > > Ken, > > Did you use the theming features of OpenJump. That is what we usually use > to see the output. > > Here is a snapshot from the latest revision of our raster chapter of our > upcoming book (due out hopefully in Mid-late February in print). > Which is the output of this query (a raster intersected with a 100 meter > radius buffer) after we apply a gradient theme. > > SELECT CAST((gval).val As integer) AS val, > ST_AsBinary((gval).geom) As geom > FROM ( > SELECT ST_Intersection(rast,1,buf.geom) As gval > FROM ch13.kauai > INNER JOIN ( > SELECT ST_Buffer( > ST_GeomFromText('POINT(444205 2438785)',26904),100) > As geom) As buf ON > ST_Intersects(rast,buf.geom)) As foo > > Also BTW: Didn't see an image attached to your email. > > Also I recall OJ has some issues with double precision and long int which > is > why we cast it to an integer > > Hope that helps, > Regina and Leo > http://www.postgis.us > > > > > > > > -Original Message- > From: postgis-users-boun...@postgis.refractions.net > [mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of > knussear > Sent: Tuesday, January 25, 2011 7:58 AM > To: postgis-users@postgis.refractions.net > Subject: Re: [postgis-users] WKTRaster problems on Mac > > > I did finally get the Open Jump call to work, and can see the polygon > output. However its not entirely useful as I intend to use map algebra etc > on the raster.. > > The attachment from qgis shows the original input raster on top of what > qgis shows for the raster. The qgis image of the postgis raster alone is > just all green (gray etc). > > Ken > > > Pierre Racine-2 wrote: >> >> Actually the image in the previous post is the original. Attached is >> what he sees when viewing the image in QGIS after it was imported in >> PostGIS raster... >> >>>-Original Message- >>>From: postgis-users-boun...@postgis.refractions.net >>>[mailto:postgis-users- boun...@postgis.refractions.net] On Behalf Of >>>Pierre Racine >>>Sent: 24 janvier 2011 16:45 >>>To: PostGIS Users Discussion >>>Subject: Re: [postgis-users] WKTRaster problems on Mac >>> >>>No but his first attempt was to open the image in QGIS. See the first > mail. I attach the image he sent >>>me as it was not attached in the first mail sent to users-postgis. >>> >>>I think this is typical of the first problem you met with the driver. >>> >>>Pierre >>> The GDAL driver is not being used in the commands I've seen. Did you execute the query Pierre suggested? SELECT ST_AsBinary((gv).geom), (gv).val FROM (SELECT ST_DumpAsPolygons(rast) gv FROM x01) foo Replacing "x01" by your table's name. -- Jorge Arévalo Internet & Mobilty Division, DEIMOS jorge.arev...@deimos-space.com http://mobility.grupodeimos.com/ http://gis4free.wordpress.com http://geohash.org/ezjqgrgzz0g ___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users >> >> >> ___ >> postgis-users mailing list >> postgis-users@postgis.refractions.net >> http://postgis.refractions.net/mailman/listinfo/postgis-users >> >> > > -- > View this message in context: > http://old.nabble.com/WKTRaster-problems-on-Mac-tp30721572p30755095.html > Sent from the PostGIS - User mailing list archive at Nabble.com. > > ___ > postgis-users mailing list > postgis-users@postgis.refractions.net > http://postgis.refractions.net/mailman/listinfo/postgis-users > > > ___ > postgis-users mailing list > postgis-users@postgis.refractions.net > http://postgis.refractions.net/mailman/listinfo/postgis-users > > -- View this message in context: http://old.nabble.com/WKTRaster-problems-on-Mac-tp30721572p30761033.html Sent from the PostGIS - User mailing list archive at Nabble.com. ___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users
Re: [postgis-users] WKTRaster problems on Mac
On Tue, Jan 25, 2011 at 1:58 PM, knussear wrote: > > I did finally get the Open Jump call to work, and can see the polygon > output. However its not entirely useful as I intend to use map algebra etc > on the raster.. > > The attachment from qgis shows the original input raster on top of what > qgis shows for the raster. The qgis image of the postgis raster alone is > just all green (gray etc). > > Ken > Hi, About MapAlgebra, we're working on it. About the plugin, I need to check the version of the plugin and the version of the GDAL driver. I think the last version of the plugin only works with the last version of GDAL Driver (GDAL 1.8) Best regards, -- Jorge Arévalo Internet & Mobilty Division, DEIMOS jorge.arev...@deimos-space.com http://mobility.grupodeimos.com/ http://gis4free.wordpress.com http://geohash.org/ezjqgrgzz0g > > Pierre Racine-2 wrote: >> >> Actually the image in the previous post is the original. Attached is what >> he sees when viewing the image in QGIS after it was imported in PostGIS >> raster... >> >>>-Original Message- >>>From: postgis-users-boun...@postgis.refractions.net [mailto:postgis-users- >>>boun...@postgis.refractions.net] On Behalf Of Pierre Racine >>>Sent: 24 janvier 2011 16:45 >>>To: PostGIS Users Discussion >>>Subject: Re: [postgis-users] WKTRaster problems on Mac >>> >>>No but his first attempt was to open the image in QGIS. See the first > mail. I attach the image he sent >>>me as it was not attached in the first mail sent to users-postgis. >>> >>>I think this is typical of the first problem you met with the driver. >>> >>>Pierre >>> The GDAL driver is not being used in the commands I've seen. Did you execute the query Pierre suggested? SELECT ST_AsBinary((gv).geom), (gv).val FROM (SELECT ST_DumpAsPolygons(rast) gv FROM x01) foo Replacing "x01" by your table's name. -- Jorge Arévalo Internet & Mobilty Division, DEIMOS jorge.arev...@deimos-space.com http://mobility.grupodeimos.com/ http://gis4free.wordpress.com http://geohash.org/ezjqgrgzz0g ___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users >> >> >> ___ >> postgis-users mailing list >> postgis-users@postgis.refractions.net >> http://postgis.refractions.net/mailman/listinfo/postgis-users >> >> > > -- > View this message in context: > http://old.nabble.com/WKTRaster-problems-on-Mac-tp30721572p30755095.html > Sent from the PostGIS - User mailing list archive at Nabble.com. > > ___ > postgis-users mailing list > postgis-users@postgis.refractions.net > http://postgis.refractions.net/mailman/listinfo/postgis-users > ___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users
Re: [postgis-users] WKTRaster problems on Mac
I did finally get the Open Jump call to work, and can see the polygon output. However its not entirely useful as I intend to use map algebra etc on the raster.. The attachment from qgis shows the original input raster on top of what qgis shows for the raster. The qgis image of the postgis raster alone is just all green (gray etc). Ken Pierre Racine-2 wrote: > > Actually the image in the previous post is the original. Attached is what > he sees when viewing the image in QGIS after it was imported in PostGIS > raster... > >>-Original Message- >>From: postgis-users-boun...@postgis.refractions.net [mailto:postgis-users- >>boun...@postgis.refractions.net] On Behalf Of Pierre Racine >>Sent: 24 janvier 2011 16:45 >>To: PostGIS Users Discussion >>Subject: Re: [postgis-users] WKTRaster problems on Mac >> >>No but his first attempt was to open the image in QGIS. See the first mail. I attach the image he sent >>me as it was not attached in the first mail sent to users-postgis. >> >>I think this is typical of the first problem you met with the driver. >> >>Pierre >> >>>The GDAL driver is not being used in the commands I've seen. Did you >>>execute the query Pierre suggested? >>> >>>SELECT ST_AsBinary((gv).geom), (gv).val >>>FROM (SELECT ST_DumpAsPolygons(rast) gv FROM x01) foo >>> >>>Replacing "x01" by your table's name. >>> >>>-- >>>Jorge Arévalo >>>Internet & Mobilty Division, DEIMOS >>>jorge.arev...@deimos-space.com >>>http://mobility.grupodeimos.com/ >>>http://gis4free.wordpress.com >>>http://geohash.org/ezjqgrgzz0g >>>___ >>>postgis-users mailing list >>>postgis-users@postgis.refractions.net >>>http://postgis.refractions.net/mailman/listinfo/postgis-users > > > ___ > postgis-users mailing list > postgis-users@postgis.refractions.net > http://postgis.refractions.net/mailman/listinfo/postgis-users > > -- View this message in context: http://old.nabble.com/WKTRaster-problems-on-Mac-tp30721572p30755095.html Sent from the PostGIS - User mailing list archive at Nabble.com. ___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users
[postgis-users] John Zhang wants to stay in touch on LinkedIn
LinkedIn I'd like to add you to my professional network on LinkedIn. - John Zhang John Zhang GIS Analyst/Developer/Technologist Vancouver, Canada Area Confirm that you know John Zhang https://www.linkedin.com/e/k871to-gjckrwkr-3d/isd/2205644117/kaTTV2dM/ -- (c) 2010, LinkedIn Corporation___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users
[postgis-users] John Zhang wants to stay in touch on LinkedIn
LinkedIn I'd like to add you to my professional network on LinkedIn. - John Zhang John Zhang GIS Analyst/Developer/Technologist Vancouver, Canada Area Confirm that you know John Zhang https://www.linkedin.com/e/k871to-gjckr6vq-12/isd/2205644117/kaTTV2dM/ -- (c) 2010, LinkedIn Corporation___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users
Re: [postgis-users] Using cleangeometry() on only the Multipolygons in a field of type geometry
On Mon, Jan 24, 2011 at 09:35:52PM -0500, Pete Yunker wrote: > We have a field of type geometry containing both Multipolygon and Point > entities. How can cleangeometry be used on only the Multipolygons, since > cleangeometry cannot be used on a field of type geometry? > > The following query fails with "ERROR: function cleangeometry(geometry) does > not exist" .. > 1.3.6 PostGIS > 3.1.0 GEOS cleangeometry is a contributed procedure. PostGIS itself has an ST_MakeValid, which does a similar thing, but only starting with version 2.0.0 (available trough the source repository, but not released yet). You might have missed to install the contributed procedure, which I guess you found on the PostGIS wiki. --strk; () Free GIS & Flash consultant/developer /\ http://strk.keybit.net/services.html ___ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users