public inbox for [email protected]  
help / color / mirror / Atom feed
From: Daniel Gustafsson <[email protected]>
To: [email protected]
To: [email protected]
Subject: Re: Missing File weather.txt
Date: Tue, 28 Jan 2020 11:18:02 +0100
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>

> On 28 Jan 2020, at 03:22, PG Doc comments form <[email protected]> wrote:
> 
> The following documentation comment has been logged on the website:
> 
> Page: https://www.postgresql.org/docs/12/tutorial-populate.html
> Description:
> 
> On this page https://www.postgresql.org/docs/12/tutorial-populate.html you
> have this command:
> 
> COPY weather FROM '/home/user/weather.txt';
> 
> I've searched all over for weather.txt and can't find it. Please could you
> make this and any other files required for the tutorial available and
> provide clear instructions for accessing them at the beginning of the
> tutorial.

This is only mentioned as an example of another input method, with a link to
the COPY page for more information.  That being said, it's a good thing for a
tutorial to be self-contained, and going from a basic tutorial to the COPY
reference page is a fairly large step.  I propose that we add a small example
on what weather.txt could look like as per the attached diff.

cheers ./daniel



Attachments:

  [application/octet-stream] tutorial_weather.diff (908B, 2-tutorial_weather.diff)
  download | inline diff:
diff --git a/doc/src/sgml/query.sgml b/doc/src/sgml/query.sgml
index c0889743c4..9608541915 100644
--- a/doc/src/sgml/query.sgml
+++ b/doc/src/sgml/query.sgml
@@ -266,8 +266,16 @@ COPY weather FROM '/home/user/weather.txt';
 
     where the file name for the source file must be available on the
     machine running the backend process, not the client, since the backend process
-    reads the file directly.  You can read more about the
-    <command>COPY</command> command in <xref linkend="sql-copy"/>.
+    reads the file directly.  An example input file is shown below, note that
+    the white space on each line is actually a tab character.
+
+<programlisting>
+San Francisco    46    50    0.25    1994-11-27
+Hayward    37    54    0.0    1994-11-29
+</programlisting>
+
+    You can read more about the <command>COPY</command> command in
+    <xref linkend="sql-copy"/>.
    </para>
   </sect1>
 


reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected]
  Subject: Re: Missing File weather.txt
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox