<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="https://kvwmap.de/wiki/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="de">
		<id>https://kvwmap.de/wiki/index.php?action=history&amp;feed=atom&amp;title=Shape-Daten_in_der_Datenbank_zusammenf%C3%BCgen</id>
		<title>Shape-Daten in der Datenbank zusammenfügen - Versionsgeschichte</title>
		<link rel="self" type="application/atom+xml" href="https://kvwmap.de/wiki/index.php?action=history&amp;feed=atom&amp;title=Shape-Daten_in_der_Datenbank_zusammenf%C3%BCgen"/>
		<link rel="alternate" type="text/html" href="https://kvwmap.de/wiki/index.php?title=Shape-Daten_in_der_Datenbank_zusammenf%C3%BCgen&amp;action=history"/>
		<updated>2026-04-28T05:32:23Z</updated>
		<subtitle>Versionsgeschichte dieser Seite in kvwmap</subtitle>
		<generator>MediaWiki 1.23.1</generator>

	<entry>
		<id>https://kvwmap.de/wiki/index.php?title=Shape-Daten_in_der_Datenbank_zusammenf%C3%BCgen&amp;diff=2393&amp;oldid=prev</id>
		<title>Heinz Schmidt am 23. Oktober 2006 um 07:17 Uhr</title>
		<link rel="alternate" type="text/html" href="https://kvwmap.de/wiki/index.php?title=Shape-Daten_in_der_Datenbank_zusammenf%C3%BCgen&amp;diff=2393&amp;oldid=prev"/>
				<updated>2006-10-23T07:17:50Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Nächstältere Version&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Version vom 23. Oktober 2006, 07:17 Uhr&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Zeile 3:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Zeile 3:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Man könnte auch die Shape-Files vereinigen und dann einen Shape-File in die Datenbank einlesen. &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Man könnte auch die Shape-Files vereinigen und dann einen Shape-File in die Datenbank einlesen. &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Einfacher ist es PostGIS dieses machen zu lassen :-)&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Einfacher ist es PostGIS dieses machen zu lassen :-)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Man erzeugt mit dem Kommando ''shp2pgsql'' eine SQL-Datei für die entsprechende Tabelle &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;jeweils für jeden &lt;/del&gt;Shape-&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;File&lt;/del&gt;.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Man erzeugt mit dem Kommando ''shp2pgsql'' &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;mit dem Parameter -c &lt;/ins&gt;eine SQL-Datei für die &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;Erzeugung der &lt;/ins&gt;entsprechende &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;DB-&lt;/ins&gt;Tabelle &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;und die Daten des ersten &lt;/ins&gt;Shape-&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;Files&lt;/ins&gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Beispiel Erzeugung der SQL-&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;Dateien &lt;/del&gt;mit den Daten &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;der &lt;/del&gt;Shapefiles &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;die vereinigt werden sollen&lt;/del&gt;:&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Beispiel Erzeugung der &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;ersten &lt;/ins&gt;SQL-&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;Datei &lt;/ins&gt;mit den Daten &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;des &lt;/ins&gt;Shapefiles:&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160; /usr/local/pgsql/bin/shp2pgsql -c /datenpfad_zum_shapefile/shape1.shp -s 2398 tabellenname&amp;#160; &amp;gt; daten_aus_shape1.sql &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160; /usr/local/pgsql/bin/shp2pgsql -c /datenpfad_zum_shapefile/shape1.shp -s 2398 tabellenname&amp;#160; &amp;gt; daten_aus_shape1.sql &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160; /usr/local/pgsql/bin/shp2pgsql -&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;c &lt;/del&gt;/datenpfad_zum_shapefile/shape2.shp -s 2398 tabellenname&amp;#160; &amp;gt; daten_aus_shape2.sql &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;Für die folgedateien benutzt man den Parameter -a für shp2pgsql.&amp;lt;br&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;Beispiel für die Erzeugung der SQL-Dateien der folgenden Shape-Files, die zusammengefügt werden sollen.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160; /usr/local/pgsql/bin/shp2pgsql -&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;a &lt;/ins&gt;/datenpfad_zum_shapefile/shape2.shp -s 2398 tabellenname&amp;#160; &amp;gt; daten_aus_shape2.sql &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160; ...&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160; ...&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Wichtig ist, dass man als user postgres in einem Verzeichnis steht, in dem man Schreibrechte hat. Die Angabe des EPSG-Codes sollte auch nicht fehlen, hier 2398. Die Pfade sind entsprechend anzupassen.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Wichtig ist, dass man als user postgres in einem Verzeichnis steht, in dem man Schreibrechte hat. Die Angabe des EPSG-Codes sollte auch nicht fehlen, hier 2398. Die Pfade sind entsprechend anzupassen.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Dann in pgAdmin III die erste SQL-Datei öffnen und die Kommandos abschicken. Anschließend die weiteren Dateien in pgAdmin III öffnen und &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;nur die darin enthaltenen INSERT-Statements &lt;/del&gt;abschicken&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;, also das CREATE TABLE u.a. entfernen, weil die Tabelle ja schon besteht und nur neue Datensätze hinzugefügt werden sollen&lt;/del&gt;. Geht alles in Windeseile! Die Datenstruktur der Shapfiles muss aber gleich sein!&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Dann in pgAdmin III die erste SQL-Datei öffnen und die Kommandos abschicken. Anschließend die weiteren Dateien in pgAdmin III öffnen und abschicken. Geht alles in Windeseile! Die Datenstruktur der Shapfiles muss aber gleich sein!&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;:--[[Benutzer:Markus Hentschel|Markus Hentschel]] 07:26, 19. Okt 2006 (CEST) Das geht noch einfacher! shp2pgsql bietet verschiedene Optionen für das Einlesen an. Sie verwenden hier &amp;quot;-c&amp;quot;, d.h. &amp;quot;Lege eine neue Tabelle an und fülle sie&amp;quot;. Es gibt z.B. auch &amp;quot;-a&amp;quot;, d.h. &amp;quot;Schreibe das Shape in eine bestehende Tabelle, wenn das Schema exakt gleich ist&amp;quot;. Geben Sie als Befehl einfach mal &amp;quot;shp2pgsql&amp;quot; ein, dann bekommen Sie alle möglichen Optionen angezeigt.&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Heinz Schmidt</name></author>	</entry>

	<entry>
		<id>https://kvwmap.de/wiki/index.php?title=Shape-Daten_in_der_Datenbank_zusammenf%C3%BCgen&amp;diff=2383&amp;oldid=prev</id>
		<title>Markus Hentschel am 19. Oktober 2006 um 05:26 Uhr</title>
		<link rel="alternate" type="text/html" href="https://kvwmap.de/wiki/index.php?title=Shape-Daten_in_der_Datenbank_zusammenf%C3%BCgen&amp;diff=2383&amp;oldid=prev"/>
				<updated>2006-10-19T05:26:41Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Nächstältere Version&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Version vom 19. Oktober 2006, 05:26 Uhr&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Zeile 14:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Zeile 14:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Dann in pgAdmin III die erste SQL-Datei öffnen und die Kommandos abschicken. Anschließend die weiteren Dateien in pgAdmin III öffnen und nur die darin enthaltenen INSERT-Statements abschicken, also das CREATE TABLE u.a. entfernen, weil die Tabelle ja schon besteht und nur neue Datensätze hinzugefügt werden sollen. Geht alles in Windeseile! Die Datenstruktur der Shapfiles muss aber gleich sein!&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Dann in pgAdmin III die erste SQL-Datei öffnen und die Kommandos abschicken. Anschließend die weiteren Dateien in pgAdmin III öffnen und nur die darin enthaltenen INSERT-Statements abschicken, also das CREATE TABLE u.a. entfernen, weil die Tabelle ja schon besteht und nur neue Datensätze hinzugefügt werden sollen. Geht alles in Windeseile! Die Datenstruktur der Shapfiles muss aber gleich sein!&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;:--[[Benutzer:Markus Hentschel|Markus Hentschel]] 07:26, 19. Okt 2006 (CEST) Das geht noch einfacher! shp2pgsql bietet verschiedene Optionen für das Einlesen an. Sie verwenden hier &amp;quot;-c&amp;quot;, d.h. &amp;quot;Lege eine neue Tabelle an und fülle sie&amp;quot;. Es gibt z.B. auch &amp;quot;-a&amp;quot;, d.h. &amp;quot;Schreibe das Shape in eine bestehende Tabelle, wenn das Schema exakt gleich ist&amp;quot;. Geben Sie als Befehl einfach mal &amp;quot;shp2pgsql&amp;quot; ein, dann bekommen Sie alle möglichen Optionen angezeigt.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Markus Hentschel</name></author>	</entry>

	<entry>
		<id>https://kvwmap.de/wiki/index.php?title=Shape-Daten_in_der_Datenbank_zusammenf%C3%BCgen&amp;diff=2382&amp;oldid=prev</id>
		<title>Heinz Schmidt am 18. Oktober 2006 um 14:13 Uhr</title>
		<link rel="alternate" type="text/html" href="https://kvwmap.de/wiki/index.php?title=Shape-Daten_in_der_Datenbank_zusammenf%C3%BCgen&amp;diff=2382&amp;oldid=prev"/>
				<updated>2006-10-18T14:13:17Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Neue Seite&lt;/b&gt;&lt;/p&gt;&lt;div&gt;--[[Benutzer:Heinz Schmidt|Heinz Schmidt]] 16:13, 18. Okt 2006 (CEST)&amp;lt;br&amp;gt;&lt;br /&gt;
Es Bestand das Problem die Daten von mehreren Shape-Files mit gleicher Struktur (das ist Bedingung) zusammenzufügen.&lt;br /&gt;
Man könnte auch die Shape-Files vereinigen und dann einen Shape-File in die Datenbank einlesen. &lt;br /&gt;
Einfacher ist es PostGIS dieses machen zu lassen :-)&lt;br /&gt;
Man erzeugt mit dem Kommando ''shp2pgsql'' eine SQL-Datei für die entsprechende Tabelle jeweils für jeden Shape-File.&lt;br /&gt;
&lt;br /&gt;
Beispiel Erzeugung der SQL-Dateien mit den Daten der Shapefiles die vereinigt werden sollen:&lt;br /&gt;
&lt;br /&gt;
 /usr/local/pgsql/bin/shp2pgsql -c /datenpfad_zum_shapefile/shape1.shp -s 2398 tabellenname  &amp;gt; daten_aus_shape1.sql &lt;br /&gt;
 /usr/local/pgsql/bin/shp2pgsql -c /datenpfad_zum_shapefile/shape2.shp -s 2398 tabellenname  &amp;gt; daten_aus_shape2.sql &lt;br /&gt;
 ...&lt;br /&gt;
&lt;br /&gt;
Wichtig ist, dass man als user postgres in einem Verzeichnis steht, in dem man Schreibrechte hat. Die Angabe des EPSG-Codes sollte auch nicht fehlen, hier 2398. Die Pfade sind entsprechend anzupassen.&lt;br /&gt;
&lt;br /&gt;
Dann in pgAdmin III die erste SQL-Datei öffnen und die Kommandos abschicken. Anschließend die weiteren Dateien in pgAdmin III öffnen und nur die darin enthaltenen INSERT-Statements abschicken, also das CREATE TABLE u.a. entfernen, weil die Tabelle ja schon besteht und nur neue Datensätze hinzugefügt werden sollen. Geht alles in Windeseile! Die Datenstruktur der Shapfiles muss aber gleich sein!&lt;/div&gt;</summary>
		<author><name>Heinz Schmidt</name></author>	</entry>

	</feed>