Results 1 to 3 of 3
  1. #1
    Join Date
    Oct 2013
    Posts
    6

    Unanswered: Transfer Ownership of Sequence Alias

    DB2 v9.7, Fix Pack 6
    DB2 Advanced Enterprise Server Edition
    DB2 Connect Server
    Windows 7 Professional, Service Pack 1

    I can transfer ownership of a table alias as follows:

    TRANSFER OWNERSHIP OF ALIAS XYZ.ACCOUNT TO USER ABC PRESERVE PRIVILEGES

    I can transfer ownership of a sequence as follows:

    TRANSFER OWNERSHIP OF SEQUENCE XYZ.ACCOUNT_SEQUENCE TO USER ABC PRESERVE PRIVILEGES

    Does anyone know how to transfer ownership of a SEQUENCE ALIAS? You can't do the following because DB2 looks for the alias in syscat.tables instead of syscat.sequences:

    TRANSFER OWNERSHIP OF ALIAS XYZ.ACCOUNT_SEQUENCE TO USER ABC PRESERVE PRIVILEGES

    Any suggestions (other than dropping and re-adding all the aliases)?

    Thanks,
    Mark B.

  2. #2
    Join Date
    Jul 2013
    Location
    Moscow, Russia
    Posts
    666
    Provided Answers: 55
    Hi Mark,

    this, should work:

    TRANSFER OWNERSHIP OF ALIAS XYZ.ACCOUNT_SEQUENCE FOR SEQUENCE TO USER ABC PRESERVE PRIVILEGES

    see the description of "alias-designator" of the TRANSFER OWNERSHIP statement.
    Regards,
    Mark.

  3. #3
    Join Date
    Oct 2013
    Posts
    6
    Thanks, fellow Mark B., that works.

    Mark B.

Posting Permissions

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