Commit e033e260 authored by Bruce Momjian's avatar Bruce Momjian

doc: adjust "cities" example to be consistent with other SQL

Reported-by: tom@crystae.net

Discussion: https://postgr.es/m/162345756191.14472.9754568432103008703@wrigleys.postgresql.org

Backpatch-through: 9.6
parent d5409295
......@@ -46,7 +46,7 @@
<programlisting>
CREATE VIEW myview AS
SELECT city, temp_lo, temp_hi, prcp, date, location
SELECT name, temp_lo, temp_hi, prcp, date, location
FROM weather, cities
WHERE city = name;
......@@ -101,12 +101,12 @@ SELECT * FROM myview;
<programlisting>
CREATE TABLE cities (
city varchar(80) primary key,
name varchar(80) primary key,
location point
);
CREATE TABLE weather (
city varchar(80) references cities(city),
city varchar(80) references cities(name),
temp_lo int,
temp_hi int,
prcp real,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment