+  my $help_text = <<"END_HELP"
+dbupgrade2_tool.pl [options]
+
+  A validation and information tool for the database upgrade scripts
+  in \'sql/Pg-upgrade2\'.
+
+  At startup dbupgrade2_tool.pl will always check the consistency
+  of all database upgrade scripts (e.g. circular references, invalid
+  formats, missing meta information). You can but don\'t have to specifiy
+  additional actions.
+
+  Actions:
+    --list               Lists all database upgrade tags
+    --tree               Lists all database upgrades in tree form
+    --rtree              Lists all database upgrades in reverse tree form
+    --graphviz[=file]    Create a Postscript document showing a tree of
+                         all database upgrades and their dependencies.
+                         If no file name is given then the output is
+                         written to \'db_dependencies.png\'.
+    --format=...         Format for the graphviz output. Defaults to
+                         \'png\'. All values that the command \'dot\' accepts
+                         for it\'s option \'-T\' are acceptable.
+    --nodeps             List all database upgrades that no other upgrade
+                         depends on
+    --create=tag         Creates a new upgrade with the supplied tag. This
+                         action accepts several optional other options. See
+                         the option section for those. After creating the
+                         upgrade file your \$EDITOR will be called with it.
+    --apply=tag          Applies the database upgrades \'tag\' and all
+                         upgrades it depends on. If \'--apply\' is used
+                         then the option \'--user\' and \'--client\' must be
+                         used as well. Use \'--apply=ALL\' to apply all.
+    --applied            List the applied database upgrades for the
+                         database that the user given with \'--user\' uses.
+    --unapplied          List the database upgrades that haven\'t been applied
+                         yet to the database that the user given with
+                         \'--user\' uses.
+    --test-utf8          Tests a PostgreSQL cluster for proper UTF-8 support.
+                         You have to specify the database to test with the
+                         parameters --dbname, --dbhost, --dbport, --dbuser
+                         and --dbpassword.
+    --help               Show this help and exit.
+
+  General Options:
+    --client=id-or-name  The name (or database ID) of the client to use for
+                         database connectivity. You must provide both a client
+                         and a user.
+    --user=name          The name of the user configuration to use for
+                         database connectivity. You must provide both a client
+                         and a user.
+    --auth-db            Work on the authentication database instead of a
+                         user database.
+    --dbname=name        Database connection options for the UTF-8
+    --dbhost=host        handling test.
+    --dbport=port
+    --dbuser=user
+    --dbpassword=pw
+
+  Options for --create:
+    --type               \'sql\' or \'pl\'. Defaults to sql.
+    --description        The description field of the generated upgrade.
+    --depends            Tags of upgrades which this upgrade depends upon.
+                         Defaults to the latest stable release upgrade.
+                         Multiple values possible.
+
+END_HELP
+;
+
+  print $help_text;
+
+  exit 0;