Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Quick SQL Question

  • 23-11-2005 9:57am
    #1
    Registered Users, Registered Users 2 Posts: 871 ✭✭✭


    Is there any way to view all of the table/ views/etc that you've created in an Oracle db? If so, how?


    Thanks
    Ger...


Comments

  • Registered Users, Registered Users 2 Posts: 68,317 ✭✭✭✭seamus


    "SHOW TABLES" works in MySQL...


  • Registered Users, Registered Users 2 Posts: 871 ✭✭✭gerTheGreat


    Nope "show tables"/ "show table", return

    SP2-0158: unknown SHOW option "tables"
    or
    SP2-0158: unknown SHOW option "table"

    (Thanks anyway;) )
    any other ideas?:confused:


  • Closed Accounts Posts: 73 ✭✭seedot


    SQL Server has a 'sysobjects' table that you can do a select on. I assume Oracle has something similar.


  • Registered Users, Registered Users 2 Posts: 68,317 ✭✭✭✭seamus


    According to Google,
    "SELECT * FROM ALL_TABLES;"

    Should work.


  • Registered Users, Registered Users 2 Posts: 871 ✭✭✭gerTheGreat


    That got it:D

    Cheers;)
    ger...


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 19,396 ✭✭✭✭Karoma


    ..glad you found it.
    SELECT whatever FROM CAT;
    should do the trick (IIRC..which i most likely don't)


  • Moderators, Politics Moderators Posts: 41,647 Mod ✭✭✭✭Seth Brundle


    SELECT * FROM USER_TABLES;
    If you throw in a wher clause, remember that the names are in upper case!


  • Registered Users, Registered Users 2 Posts: 2,781 ✭✭✭amen


    for MSSQL don't be using sys tables use the information_schema views
    MS don't guranatee that the sys tables will be the same between MS SQL version but the information_schema views should be


Advertisement