diff --git a/doc/src/sgml/ddl.sgml b/doc/src/sgml/ddl.sgml
index e9135bf..bae2e97 100644
--- a/doc/src/sgml/ddl.sgml
+++ b/doc/src/sgml/ddl.sgml
@@ -258,7 +258,7 @@ CREATE TABLE products (
    even if the value came from the default value definition.
   </para>
 
-  <sect2>
+  <sect2 id="ddl-constraints-check-constraints">
    <title>Check Constraints</title>
 
    <indexterm>
@@ -482,7 +482,7 @@ CREATE TABLE products (
    </tip>
   </sect2>
 
-  <sect2>
+  <sect2 id="ddl-constraints-unique-constraints">
    <title>Unique Constraints</title>
 
    <indexterm>
@@ -569,7 +569,7 @@ CREATE TABLE products (
    </para>
   </sect2>
 
-  <sect2>
+  <sect2 id="ddl-constraints-primary-keys">
    <title>Primary Keys</title>
 
    <indexterm>
@@ -1168,7 +1168,7 @@ CREATE TABLE circles (
    here.
   </para>
 
-  <sect2>
+  <sect2 id="ddl-alter-adding-a-column">
    <title>Adding a Column</title>
 
    <indexterm>
@@ -1212,7 +1212,7 @@ ALTER TABLE products ADD COLUMN description text CHECK (description &lt;&gt; '')
   </tip>
   </sect2>
 
-  <sect2>
+  <sect2 id="ddl-alter-removing-a-column">
    <title>Removing a Column</title>
 
    <indexterm>
@@ -1239,7 +1239,7 @@ ALTER TABLE products DROP COLUMN description CASCADE;
    </para>
   </sect2>
 
-  <sect2>
+  <sect2 id="ddl-alter-adding-a-constraint">
    <title>Adding a Constraint</title>
 
    <indexterm>
@@ -1267,7 +1267,7 @@ ALTER TABLE products ALTER COLUMN product_no SET NOT NULL;
    </para>
   </sect2>
 
-  <sect2>
+  <sect2 id="ddl-alter-removing-a-constraint">
    <title>Removing a Constraint</title>
 
    <indexterm>
diff --git a/doc/src/sgml/extend.sgml b/doc/src/sgml/extend.sgml
index bc1cd59..60fa1a8 100644
--- a/doc/src/sgml/extend.sgml
+++ b/doc/src/sgml/extend.sgml
@@ -145,7 +145,7 @@
     </para>
    </sect2>
 
-   <sect2>
+   <sect2 id="extend-type-system-domains">
     <title>Domains</title>
 
     <para>

