Results 1 to 3 of 3

Thread: Sysadmauth

  1. #1
    Join Date
    Aug 2009
    Posts
    17

    Red face Unanswered: Sysadmauth

    Hello, I was asked to do an audit on a DB2 installation then requested the query:

    SELECT GRANTEE, GRANTEETYPE, SYSADMAUTH FROM SYSIBM.SYSUSERAUTH WHERE SYSADMAUTH <>' ';

    but the DBA reports the column SYSADMAUTH does not exist:

    db2 describe table SYSIBM.SYSUSERAUTH
    Column Type Type
    name schema name Length Scale Nulls
    ------------------------------ --------- ------------------ -------- ----- ------
    GRANTEE SYSIBM VARCHAR 128 0 No
    GRANTEETYPE SYSIBM CHARACTER 1 0 No
    TABSCHEMA SYSIBM VARCHAR 128 0 No
    TABNAME SYSIBM VARCHAR 128 0 No
    AUTH_DESC SYSIBM BLOB 2097152 0 No


    What I'm missing here? my query correspond to a different version of DB2? The version is V8 on HP-UX.

  2. #2
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    You should not use SYSIBM tables to query the system catalog, as they may change between versions and releases. Use SYSCAT views instead, as recommended by IBM.
    ---
    "It does not work" is not a valid problem statement.

  3. #3
    Join Date
    Dec 2008
    Posts
    76
    First, your describe shows that there is no column named SYSADMAUTH.
    Second, Nick is correct: use SYSCAT views.
    Third - there is no data on SYSADM kept in database tables because SYSADM operates in a higher domain than a database. You can find DBAUTH privileges from the SYSCAT.DBAUTH view. SYSADM is granted to those in the SYSADM_GROUP defined in the results of "db2 get dbm cfg" which is usually run from the command line.
    RD

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •