Skip to content

Commit a114de7

Browse files
committed
reviewed chapters 1-8 on OSGeo Live and fixed small issues
1 parent 26f544f commit a114de7

File tree

4 files changed

+21
-29
lines changed

4 files changed

+21
-29
lines changed

docs/chapters/installation.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -114,14 +114,14 @@ If these requirements are met, then open a terminal window and execute the follo
114114
# login as user "user"
115115
psql -U user
116116
117-
# create routing database
117+
-- create routing database
118118
CREATE DATABASE routing;
119119
\c routing
120120
121-
# add PostGIS functions
121+
-- add PostGIS functions
122122
CREATE EXTENSION postgis;
123123
124-
# add pgRouting core functions
124+
-- add pgRouting core functions
125125
CREATE EXTENSION pgrouting;
126126
127127

docs/chapters/osm2pgrouting.rst

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ Then run the converter:
9292
-conf "/usr/share/osm2pgrouting/mapconfig.xml" \
9393
-dbname pgrouting-workshop \
9494
-user user \
95+
-host localhost \
9596
-clean
9697
9798
List of all possible parameters:
@@ -144,15 +145,6 @@ List of all possible parameters:
144145
- drop peviously created tables
145146
- no
146147

147-
.. note::
148-
149-
* There might be an updated version of osm2pgrouting available. To update the package run:
150-
151-
.. code-block:: bash
152-
153-
sudo apt-get update
154-
sudo apt-get install --only-upgrade osm2pgrouting
155-
156148

157149
Depending on the size of your network the calculation and import may take a while. After it's finished connect to your database and check the tables that should have been created:
158150

docs/chapters/topology.rst

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -132,12 +132,12 @@ First we have to add source and target column, then we run the ``pgr_createTopol
132132
Add indices
133133
-------------------------------------------------------------------------------
134134

135-
Fortunately we didn't need to wait too long because the data is small. But your network data might be very large, so it's a good idea to add an index to ``source`` and ``target`` column.
135+
Make sure that your network table has an index for ``source`` and ``target`` columns.
136136

137137
.. code-block:: sql
138138
139-
CREATE INDEX source_idx ON ways("source");
140-
CREATE INDEX target_idx ON ways("target");
139+
CREATE INDEX ways_source_idx ON ways("source");
140+
CREATE INDEX ways_target_idx ON ways("target");
141141
142142
After these steps our routing database looks like this:
143143

@@ -146,20 +146,20 @@ After these steps our routing database looks like this:
146146
.. code-block:: sql
147147
148148
List of relations
149-
Schema | Name | Type | Owner
150-
--------+---------------------+----------+----------
151-
public | geography_columns | view | user
152-
public | geometry_columns | view | user
153-
public | raster_columns | view | user
154-
public | raster_overviews | view | user
155-
public | spatial_ref_sys | table | user
156-
public | vertices_tmp | table | user
157-
public | vertices_tmp_id_seq | sequence | user
158-
public | ways | table | user
149+
Schema | Name | Type | Owner
150+
--------+--------------------------+----------+----------
151+
public | geography_columns | view | user
152+
public | geometry_columns | view | user
153+
public | raster_columns | view | user
154+
public | raster_overviews | view | user
155+
public | spatial_ref_sys | table | user
156+
public | ways_vertices_pgr | table | user
157+
public | ways_vertices_pgr_id_seq | sequence | user
158+
public | ways | table | user
159159
(9 rows)
160160
161161
* ``geography_columns`` should contain a record for each table with "geometry" attribute and its SRID.
162-
* ``vertices_tmp`` contains a list of all network nodes.
162+
* ``ways_vertices_pgr`` contains a list of all network nodes.
163163

164164

165165
.. rubric:: Run: ``\d ways``
@@ -180,8 +180,8 @@ After these steps our routing database looks like this:
180180
Indexes:
181181
"ways_gid_idx" UNIQUE, btree (gid)
182182
"geom_idx" gist (the_geom)
183-
"source_idx" btree (source)
184-
"target_idx" btree (target)
183+
"ways_source_idx" btree (source)
184+
"ways_target_idx" btree (target)
185185
186186
* ``source`` and ``target`` columns are now updated with node IDs.
187187
* ``name`` may contain the street name or be empty.

docs/chapters/wrapper.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,4 +202,4 @@ We can now install this function into the database:
202202

203203
.. code-block:: bash
204204
205-
psql -U user -d pgrouting-workshop ~/Desktop/pgrouting-workshop/data/fromAtoB.sql
205+
psql -U user -d pgrouting-workshop -f ~/Desktop/pgrouting-workshop/data/fromAtoB.sql

0 commit comments

Comments
 (0)