.
contact contact


dbdumpcat utility

» Usage | Notes | Examples | See also
 
.
  The dbdumpcat utility may be used to display database or system catalog tables.

Usage

usage: dbdumpcat [options] [database]

options:
 -u name    - user name (default "public")
 -p pswd    - password
 -h host    - host name or address (and service)
 -s service - service name or port number
 -d flags   - debug flags
 -t catid   - dump only specified catalog table
 -l         - list catalog tables
 -n         - suppress header and formatting
The options are:
-help
The -help option displays a brief help text.

-u user
The -u option specifies the database user (or a file holding the database user and/or password). Defaults to the public user unless a default user is specified with the EQ_DBUSER environment variable.

-p password
The -p option may be used to specify the password for the database user (or a file holding the password). If not specified, the password is obtained using the EQ_DBUSER and/or EQ_DBPASSWORD environment variables.

-h host[:service]
The -h option may be used to specify the database server host name (or IP address) and service name (or TCP port number). Defaults to localhost:eloqdb unless a default instance is specified with the EQ_DBSERVER environment variable.

-s service
The -s option may be used to specify the service name or TCP port number of the database server. Defaults to eloqdb unless a default instance is specified with the EQ_DBSERVER environment variable.

-t catid
The -t option allows to dump a selected catalog table (instead of all).

-l
The -l option displays a list of available catalog tables.

-n
The -n option suppresses header and formatting in output.

-d flags
The -d option specifies debug flags and is normally not used.

Notes

  • If no database is specified, the system catalog tables are dumped.

  • If a database is specified, the database specific catalog tables are shown.

  • Some catalog information is only available to dba users (e.g. password hashes).

  • The -n option may be used to display content that exceeds column width.

  • With -n option dates display as "seconds since epoch" instead of YYYY-MM-DD.

Examples

The following example lists the available system catalog tables and dumps information about database users as well as databases by specifying catalog tables #30 and #31:
dbdumpcat -l

-------------------------------------------------
| Server catalog                                |
| localhost:eloqdb                              |
|-----------------------------------------------|
| Id   | Name                           | Count |
|-----------------------------------------------|
|   20 | sysobjects                     |  1576 |
|   21 | sysdevices                     |    10 |
|   22 | sysvat                         |     0 |
|   30 | sysuser                        |    10 |
|   31 | sysdb                          |    33 |
|   32 | systables                      |    10 |
|   33 | syscolumns                     |    67 |
|   34 | sysindex                       |     0 |
|   35 | sysindexseg                    |     0 |
|   36 | syscollate                     |     6 |
-------------------------------------------------

dbdumpcat -t 30

----------------------------------------------------------------
#30 sysuser (3 entries)
----------------------------------------------------------------
|uid |name                |password        |priv    |tspw      |
----------------------------------------------------------------
|1   |dba                 |16:b9f09954fc3a |00000003|          |
|2   |public              |NULL            |00000004|          |
|3   |odbc                |NULL            |00000004|          |
----------------------------------------------------------------

dbdumpcat -t 31

-------------------------------------------
#31 sysdb (33 entries)
-------------------------------------------
|dbid|name                |flags   |nodeid|
-------------------------------------------
|11  |PPS.OLD             |00000004|100   |
|12  |PPS.NEW             |00000004|128   |
|14  |MUSIC               |00000004|473   |
|16  |TOYDB               |00000004|518   |
|17  |SAMPLE              |00000004|529   |
      ...

The following example lists available catalog tables for a given database and dumps information on groups and user membership by displaying catalog tables #2 and #5:
dbdumpcat -l MyDB

-------------------------------------------------
| Database catalog                              |
| mydb                                          |
|-----------------------------------------------|
| Id   | Name                           | Count |
|-----------------------------------------------|
|    1 | systables                      |    24 |
|    2 | sysgroup                       |     4 |
|    3 | syscolumns                     |   126 |
|    4 | sysindex                       |     3 |
|    5 | sysmember                      |     4 |
|    6 | sysprivilege                   |    12 |
|    7 | sysindexseg                    |     3 |
|    8 | systablecolumn                 |    30 |
|    9 | systableindex                  |     0 |
|   10 | systablepath                   |    12 |
|   11 | sysdbproperty                  |     0 |
|   12 | sysitemproperty                |     0 |
|   13 | syskey                         |     0 |
|   14 | sysfts                         |     0 |
|   15 | sysftsfield                    |     0 |
|   16 | sysftsseg                      |     0 |
|   17 | sysftspcfg                     |     0 |
|   18 | sysftsexcl                     |     0 |
-------------------------------------------------

dbdumpcat -t 2 MyDB

------------------------------------
#2 sysgroup (4 entries)
------------------------------------
|gid |name                |priv    |
------------------------------------
|1   |dba                 |00000003|
|2   |public              |00000000|
|3   |READING             |00000000|
|4   |WRITING             |00000000|
------------------------------------

dbdumpcat -t 5 MyDB

-----------
#5 sysmember (4 entries)
-----------
|uid |gid |
-----------
|1   |1   |
|2   |2   |
|2   |3   |
|2   |4   |
-----------

See also

Environment variables: EQ_DBUSER, EQ_DBPASSWORD, EQ_DBSERVER


 
 
 
  Privacy | Webmaster | Terms of use | Impressum Revision: 2014-09-05  
  Copyright © 1995-2024 Marxmeier Software AG