Yeah, I think the info is gone, because ST_LineToCurve looks the same.
As a test I changed my map file from:
DATA 'the_geom FROM washingtonmn.streets using unique gid using srid=3857'
TO:
DATA 'the_geom FROM (select gid, fullstreet, st_LineToCurve(the_geom) as
the_geom from washingtonmn.streets) as subq using unique gid using
srid=3857'
And it displays the same either way.
I am using FileGDB:
ogrinfo -so WCWebDataCC.gdb/
INFO: Open of `WCWebDataCC.gdb/'
using driver `FileGDB' successful.
The command I'm using is:
ogr2ogr -f PostgreSQL
-lco FID=gid
-lco SPATIAL_INDEX=OFF
-lco GEOMETRY_NAME=the_geom
-lco SCHEMA=washingtonmn
-lco PRECISION=NO
-lco DIM=2
-t_srs EPSG:3857
-nlt MULTILINESTRING
'PG:dbname=gis'
WCWebDataCC.gdb
Is the "-nlt MULTILINESTRING" doing bad things? Its in there because
some times I get layers marked as LINESTRING that dont convert so I just
up them to MULTILINESTRING to get it to go.
Thanks again,
-Andy
On 11/12/2014 9:03 AM, Rémi Cura wrote:
Good, you narrowed the error.
The function would do it for you,
it would convert the curved parts into curves and the straight part into
segment,
forming a curved polygon, which is a set of curve and segments.
But I'm affraid your line must appoximate the curves to have a result.
Your 2 first screen shots indicate that the curve information is simply
gone.
You can manually approximate curves into line in arcgis before export,
or maybe OGR driver for arcgis support curves
(http://www.gdal.org/drv_filegdb.html)
Cheers,
Rémi-C
2014-11-12 15:56 GMT+01:00 Andy Colson <a...@squeakycode.net
<mailto:a...@squeakycode.net>>:
Mapserver displays it the same way:
http://testmaps.camavision.__com/map/washingtonmn?pin=16.__028.21.11.0039
<http://testmaps.camavision.com/map/washingtonmn?pin=16.028.21.11.0039>
The data looks like:
gis=# select st_AsText(the_geom) from streets where gid = 11517;
-[ RECORD 1
]-----------------------------__------------------------------__------------------------------__------------------------------__------------------------------__------------------------------__------------------------------__------------------------------__------------------------------__------------------------------__------------------------------__-
st_astext | MULTILINESTRING((-10344354.__4038468
5608573.22422463,-10344363.__9860388
5608565.68874797,-10344398.__9885982
5608528.81799097,-10344438.__5518419
5608468.68094317,-10344404.__2129173
5608265.5414558,-10344355.__0291817
5608227.92219317,-10344239.__0250123
5608196.3261761,-10344230.__7760714
5608197.59004929,-10344187.__3835781 5608212.14184435))
So I'm assuming that its a convert problem, not a display problem.
I'm not sure how to use ST_LineToCurve. This is a road layer and
everything is a MULTILINESTRING, I can't tell the straight from the
curves. Can I?
Thanks,
-Andy
On 11/12/2014 3:58 AM, Rémi Cura wrote:
Hey,
first qgis can't deal with curve (i think),
so your data may be curved in your postgis but the visualisation
would
be incorrect
so if you are going to see some curve in qgis, you have to
convert the
curve to approximate theim using
http://postgis.net/docs/ST___CurveToLine.html
<http://postgis.net/docs/ST_CurveToLine.html>,
then display the geom
(you can do this in a view if you don't want to duplicate data)
Now if you are really really sure that data in postgis is bad (use
ST_AsTExt(geom) for example to see if anything look like curve)
Either you approximate your curve with multiline and convert it
back to
curve with postgis
(http://postgis.net/docs/ST___LineToCurve.html
<http://postgis.net/docs/ST_LineToCurve.html>)
Or you have to go the long way and pass the curves as
attributes, and
reconstruct it afterward.
This seems like a very bad idea.
I'm afraid curve support is very very limited in all gis tools.
Cheers,
Rémi-C
2014-11-12 0:00 GMT+01:00 Andy Colson <a...@squeakycode.net
<mailto:a...@squeakycode.net>
<mailto:a...@squeakycode.net <mailto:a...@squeakycode.net>>>__:
Hi All,
Not sure where the best place to ask this, so I'll start here.
I have a FileGDB that contains some curved lines, I import
it into
PostGIS and they come out as chopped off Multiline.
Here are some screen shots to help explain:
Here is arc viewing the .gdb:
http://testmaps.camavision.____com/arc.png
<http://testmaps.camavision.__com/arc.png
<http://testmaps.camavision.com/arc.png>>
Here is qgis viewing PostGIS:
http://testmaps.camavision.____com/qgis.png
<http://testmaps.camavision.__com/qgis.png
<http://testmaps.camavision.com/qgis.png>>
I tried to get arcCatalog to export to shapefile, but
something went
bad and I cannot even look at the .shp files.
Any hints how I can get the curve back?
Thanks for your time,
-Andy
_______________________________________________
postgis-users mailing list
postgis-users@lists.osgeo.org
http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users