Documentation enhancement

Поиск
Список
Период
Сортировка
Искать

Documentation enhancement

От:
Thomas Kellerer <spam_eater@gmx.net>
Дата:
Hi,

I would like to suggest to enhance the documentation of the CREATE VIEW statement.

I think the fact that a "SELECT *" is internally stored as the expanded column list (valid at the time when the view was created) should be documented together with the CREATE VIEW statement. Especially because the example does use SELECT * to create the view.

Regards
Thomas




Re: Documentation enhancement

От:
Bruce Momjian <bruce@momjian.us>
Дата:
Thomas Kellerer wrote:
> Hi,
> 
> I would like to suggest to enhance the documentation of the CREATE VIEW
> statement.
> 
> I think the fact that a "SELECT *" is internally stored as the expanded
> column list (valid at the time when the view was created) should be
> documented together with the CREATE VIEW statement. Especially because
> the example does use SELECT * to create the view.

Agreed.  The attached, applied patch documents this behavior.

--
  Bruce Momjian          http://momjian.us
  EnterpriseDB                             http://enterprisedb.com

  + It's impossible for everything to be true. +
diff --git a/doc/src/sgml/ref/create_view.sgml b/doc/src/sgml/ref/create_view.sgml
index dd15507..417f8c3 100644
*** a/doc/src/sgml/ref/create_view.sgml
--- b/doc/src/sgml/ref/create_view.sgml
*************** CREATE VIEW comedies AS
*** 173,178 ****
--- 173,182 ----
      FROM films
      WHERE kind = 'Comedy';
  
+    This will create a view containing the columns that are in the
+    film</> table at the time of view creation.  Though
+    *</> was used to create the view, columns added later to
+    the table will not be part of the view.
    
   
  
FAQ