Results 1 to 5 of 5
  1. #1
    Join Date
    Aug 2008
    Posts
    2

    Unanswered: List Table Names within a Schema

    Hi members,
    I am looking for a SQL Query which will give me a list of tables from a schema.
    All the tables in the schema have a column called "created_by". And, each of these tables are populated using ETL processes by different users, say for example USER1, USER2, USER3 and so on. When the ETL process updates by logging as a user, the field "created by" is updated by the user name... USER1 or USER2 or USER3 etc.

    I would like to know which tables are populated by USER2 in a schema.
    I am using Oracle 10g on Windows 2003. Please need you help.

    Thanks in Advance.
    Irfan
    Last edited by irfanahmed786; 08-25-08 at 17:12.

  2. #2
    Join Date
    Jan 2003
    Location
    Massachusetts
    Posts
    5,800
    Provided Answers: 11
    The ALL_TABLES view will give you a list of tables within a schema. You, however, appear to be asking how to find all tables with a particular value in a particular column. This does not exist.

  3. #3
    Join Date
    Aug 2008
    Posts
    9

    Little piece of code

    Hi irfan, if i am right, you want to list all the tables whose a particular column has a particular value. I had a similar requirement sometime back and I used this little piece of code at sql prompt, which I found after searching on the net.

    This code when executed at SQL*Plus prompt, builds and runs SQL to find all user tables with a particular column and value, spools the results to a file, and opens the file in Notepad.

    Hope it helps.
    Attached Files Attached Files

  4. #4
    Join Date
    Aug 2008
    Posts
    2
    Thank you MCrowley and Sadik bhai for the script.

  5. #5
    Join Date
    Aug 2008
    Posts
    9
    you are most welcome...

Posting Permissions

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