<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.E-MailFormatvorlage17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 2.0cm 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=DE link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Hi everyone,<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I am relatively new to using OSM data and osm2pgsql and have been doing some testing during the last few weeks. I am using the following command lines and I am pretty not sure, if I am doing it in the right way:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><b><i>osm2pgsql --verbose --create --slim --cache 4096 --prefix planet_osm --database osmtest --username gis --host localhost --hstore --extra-attributes --style /gis/maps/planet/style/default.style --number-processes 4 --bbox 7.85,51.50,11.32,55.06 schleswig-holstein-latest.osm.pbf<o:p></o:p></i></b></p><p class=MsoNormal><b><i><o:p> </o:p></i></b></p><p class=MsoNormal><b><i>osm2pgsql --verbose --append --slim --cache 4096 --prefix planet_osm --database osmtest --username gis --host localhost --hstore --extra-attributes --style /gis/maps/planet/style/default.style --number-processes 4 --bbox 7.85,51.50,11.32,55.06 hamburg-latest.osm.pbf<o:p></o:p></i></b></p><p class=MsoNormal><b><i><o:p> </o:p></i></b></p><p class=MsoNormal><b><i>osm2pgsql --verbose --append --slim --cache 4096 --prefix planet_osm --database osmtest --username gis --host localhost --hstore --extra-attributes --style /gis/maps/planet/style/default.style --number-processes 4 --bbox 7.85,51.50,11.32,55.06 niedersachsen-latest.osm.pbf<o:p></o:p></i></b></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>The result should be a "merging" of 3 osm data files, the first line is doing a good job , but during the second line there is an error:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><b><span style='color:red'>Reading in file: hamburg-latest.osm.pbf<o:p></o:p></span></b></p><p class=MsoNormal><b><span style='color:red'>Processing: Node(2156k 113.5k/s) Way(405k 27.00k/s) Relation(0 0.00/s)COPY_END for COPY planet_osm_ways FROM STDIN;<o:p></o:p></span></b></p><p class=MsoNormal><b><span style='color:red'>failed: ERROR:  duplicate key value violates unique constraint "planet_osm_ways_pkey"<o:p></o:p></span></b></p><p class=MsoNormal><b><span style='color:red'>DETAIL:  Key (id)=(3075476) already exists.<o:p></o:p></span></b></p><p class=MsoNormal><b><span style='color:red'>CONTEXT:  COPY planet_osm_ways, line 193<o:p></o:p></span></b></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I would be glad if anyone could tell me, what I have missed and what I am doing wring here? Thanks a lot,<o:p></o:p></p><p class=MsoNormal>Stefan<o:p></o:p></p></div></body></html>