Skip to content

Commit 4361e0d

Browse files
committed
Merge Tom and my descriptions of new sequence behavior into one entry.
1 parent 07e7430 commit 4361e0d

File tree

1 file changed

+19
-30
lines changed

1 file changed

+19
-30
lines changed

doc/src/sgml/release.sgml

Lines changed: 19 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!--
2-
$PostgreSQL: pgsql/doc/src/sgml/release.sgml,v 1.382 2005/10/03 01:57:59 momjian Exp $
2+
$PostgreSQL: pgsql/doc/src/sgml/release.sgml,v 1.383 2005/10/03 02:21:16 momjian Exp $
33

44
Typical markup:
55

@@ -262,21 +262,6 @@ pg_[A-Za-z0-9_] <application>
262262

263263
<itemizedlist>
264264

265-
<listitem>
266-
<para>
267-
<varname>Add proper sequence function dependencies (Tom)
268-
</para>
269-
<para>
270-
In previous releases, <function>nextval()</>,
271-
<function>currval</>, and <function>setval()</> recorded
272-
sequence names as simple text strings, meaning that renaming or
273-
dropping a sequence used in a <command>DEFAULT</> made the
274-
clause invalid. This release stores all newly-created sequence
275-
function arguments using internal oids, allowing them to handle
276-
sequence renaming, and adding dependency information that
277-
</para>
278-
</listitem>
279-
280265
<listitem>
281266
<para>
282267
<varname>add_missing_from</> is now false by default (Neil)
@@ -408,22 +393,25 @@ pg_[A-Za-z0-9_] <application>
408393

409394
<listitem>
410395
<para>
411-
Sequence arguments of <function>nextval()</> and related functions
412-
are now bound early by default (Tom)
396+
<varname>Add proper sequence function dependencies for <command>
397+
DEFAULT</> clauses (Tom)
398+
</para>
399+
<para>
400+
In previous releases, <function>nextval()</>,
401+
<function>currval</>, and <function>setval()</> recorded
402+
sequence names as simple text strings, meaning that renaming or
403+
dropping a sequence used in a <command>DEFAULT</> made the
404+
clause invalid. This release stores all newly-created sequence
405+
function arguments using internal OIDs, allowing them to handle
406+
sequence renaming, and adding dependency information that
407+
prevents improper sequence removal. It also makes
408+
<command>DEFAULT</> clauses immune to schema search
409+
path changes.
413410
</para>
414411
<para>
415-
When an expression like <literal>nextval('myseq')</> appears in a
416-
column <command>DEFAULT</> expression or view, the referenced
417-
sequence (here <literal>myseq</>) is now looked up immediately,
418-
and its pg_class OID is placed in the stored expression. This
419-
representation will survive renaming of the referenced sequence,
420-
as well as changes in schema search paths. The system also
421-
understands that the sequence reference represents a dependency,
422-
so the sequence cannot be dropped without dropping the
423-
referencing object. Previous releases stored this information as
424-
a simple text string, with none of the benefits outlined above.
425-
To get the old text-based behavior of run-time lookup of the
426-
sequence name, cast the argument to <type>text</>, for example
412+
Some applications might rely on the old text-based behavior of
413+
run-time lookup of the sequence name. This can still be done by
414+
casting the argument to <type>text</>, for example
427415
<literal>nextval('myseq'::text)</>.
428416
</para>
429417
<para>
@@ -13495,3 +13483,4 @@ sgml-local-catalogs:("/usr/lib/sgml/catalog")
1349513483
sgml-local-ecat-files:nil
1349613484
End:
1349713485
-->
13486+

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