Results 1 to 4 of 4
  1. #1
    Join Date
    Mar 2003
    Location
    Singapore
    Posts
    200

    Unanswered: Track the SQL statements

    Hi all,


    Is there a method in db2 with which we can track the sql statments that are run against the database.I meant something like Log miner in Oracle with which be can get a history of the sql stmts run.

    This is because i need to find which statement is creating the temp tablespace to become full .

    Thanks

    micky

  2. #2
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650

    Re: Track the SQL statements

    Statement Event Monitor : This records every statement run against the database ..

    Check the System Monitor guide and reference for details ...

    The following are steps :

    1) Define Event Monitor for Sql statements
    2) Activate it
    All Statements against the database are captured
    3) Deactivate the monitor
    4) Use the db2evmon utility to get the information from the monitor

    HTH

    Sathyaram

    Originally posted by mickykt
    Hi all,


    Is there a method in db2 with which we can track the sql statments that are run against the database.I meant something like Log miner in Oracle with which be can get a history of the sql stmts run.

    This is because i need to find which statement is creating the temp tablespace to become full .

    Thanks

    micky
    Visit the new-look IDUG Website , register to gain access to the excellent content.

  3. #3
    Join Date
    Jan 2003
    Posts
    1,605

    Re: Track the SQL statements

    Hi,

    If you have problems with DB2 (temp tablespace full) check the db2diag.log (diagnostic file) - you can get some useful information.

    To check the SQLs running against your dabase use Event Monitor tool.

    Hope this helps,
    Grofaty


    Originally posted by mickykt
    Hi all,


    Is there a method in db2 with which we can track the sql statments that are run against the database.I meant something like Log miner in Oracle with which be can get a history of the sql stmts run.

    This is because i need to find which statement is creating the temp tablespace to become full .

    Thanks

    micky

  4. #4
    Join Date
    Mar 2003
    Location
    Singapore
    Posts
    200
    Hi all,

    thanks for ur advice,I will be setting an sql EM to track the sql that creats the issue.

    thanks
    micky

Posting Permissions

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