[OSM-dev] osm2pgsql

Emilie Laffray emilie.laffray at gmail.com
Tue Jun 8 15:57:32 BST 2010


On 8 June 2010 15:49, <bdepaepe at latitude-geosystems.com> wrote:

> hi,
>
> I try to import france.osm (obtained from downloads.cloudmade.com)
> into PostGIS db using :
> osm2pgsql -U postgres -W -E 900913 -s -d osm_france
> /home/bart/Desktop/france.osm
>
> The import encounters an error and terminates:
> ***
> Reading in file: /home/bart/Desktop/france.osm
> Processing: Node(38320k) Way(0k) Relation(0k)COPY_END for COPY
> planet_osm_nodes FROM STDIN;
>  failed: ERROR:  duplicate key value violates unique constraint
> "planet_osm_nodes_pkey"
> CONTEXT:  COPY planet_osm_nodes, line 8934: "361095     625272091
>  26207008        {"highway","traffic_signals"}"
> ***
>
> I found an old post on your mailing list about this error:
> http://lists.openstreetmap.org/pipermail/dev/2008-August/011579.html
>
> However, when looking into my osm2pgsql.c this patch has been
> implemented in the meantime so it should work.
>
> The import of belgium.osm encountered the same error, so it is not due
> to the input file.
>
> thanks for your help,
>


Hello,

CloudMade osm files are known to contain duplication of nodes sometimes.
This is what you are seeing with the database constraint not being happy
since you are trying to import the same point probably with 2 different
versions.
The issue you are reporting is not related to what you are mentioning.

Emilie Laffray
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/dev/attachments/20100608/5b7f56a9/attachment.html>


More information about the dev mailing list