Skip to content

Commit 6eee73e

Browse files
committed
doc: Use tags consistently in the tutorial chapter
Make more consistent use of <screen> and <programlisting>. Author: Jürgen Purtz <juergen@purtz.de> Discussion: https://www.postgresql.org/message-id/flat/158996922318.7035.10603922579567326239@wrigleys.postgresql.org
1 parent 96cfcad commit 6eee73e

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

doc/src/sgml/query.sgml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -564,14 +564,16 @@ SELECT *
564564
<programlisting>
565565
SELECT *
566566
FROM weather LEFT OUTER JOIN cities ON (weather.city = cities.name);
567+
</programlisting>
567568

569+
<screen>
568570
city | temp_lo | temp_hi | prcp | date | name | location
569571
---------------+---------+---------+------+------------+---------------+-----------
570572
Hayward | 37 | 54 | | 1994-11-29 | |
571573
San Francisco | 46 | 50 | 0.25 | 1994-11-27 | San Francisco | (-194,53)
572574
San Francisco | 43 | 57 | 0 | 1994-11-29 | San Francisco | (-194,53)
573575
(3 rows)
574-
</programlisting>
576+
</screen>
575577

576578
This query is called a <firstterm>left outer
577579
join</firstterm> because the table mentioned on the left of the
@@ -612,13 +614,15 @@ SELECT W1.city, W1.temp_lo AS low, W1.temp_hi AS high,
612614
FROM weather W1, weather W2
613615
WHERE W1.temp_lo &lt; W2.temp_lo
614616
AND W1.temp_hi &gt; W2.temp_hi;
617+
</programlisting>
615618

619+
<screen>
616620
city | low | high | city | low | high
617621
---------------+-----+------+---------------+-----+------
618622
San Francisco | 43 | 57 | San Francisco | 46 | 50
619623
Hayward | 37 | 54 | San Francisco | 46 | 50
620624
(2 rows)
621-
</programlisting>
625+
</screen>
622626

623627
Here we have relabeled the weather table as <literal>W1</literal> and
624628
<literal>W2</literal> to be able to distinguish the left and right side

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy