Solved

Retrieving Table Names and Column data from Oracle database

Posted on 2008-10-29
4
1,529 Views
Last Modified: 2012-05-05
Hi all,
I am wanting to find a way to programtically retrieve the table names, column names, column specifications (length, type etc.) from an Oracle database. So maybe using an OracelDataReader or something like that. Or maybe there is some SQL that will help me achieve this.

I would like the solution in Vb.Net or C#.
0
Comment
Question by:M3mph15
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 250 total points
ID: 22838453
you can query the view DBA_TAB_COLUMNS
www.ss64.com/orad/DBA_TAB_COLUMNS.html
0
 
LVL 6

Author Comment

by:M3mph15
ID: 22838521
hi, tried to retireve data in SQL Plus. SQL statement:
select column_name,data_type, nullable from dba_tab_columns where rownum < 50;
it says: table or view does not exist
0
 
LVL 27

Assisted Solution

by:sujith80
sujith80 earned 250 total points
ID: 22838593
Probably you dont have privileges to access dba_tab_columns.

You may try to use ALL_TAB_COLUMNS instead.
0
 
LVL 6

Author Comment

by:M3mph15
ID: 22838697
Hi,
Yes it was that i didn't have the right privileges. Thanks to the both of you
0

Featured Post

MIM Survival Guide for Service Desk Managers

Major incidents can send mastered service desk processes into disorder. Systems and tools produce the data needed to resolve these incidents, but your challenge is getting that information to the right people fast. Check out the Survival Guide and begin bringing order to chaos.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Confronted with some SQL you don't know can be a daunting task. It can be even more daunting if that SQL carries some of the old secret codes used in the Ye Olde query syntax, such as: (+)     as used in Oracle;     *=     =*    as used in Sybase …
When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database
This video shows how to Export data from an Oracle database using the Original Export Utility.  The corresponding Import utility, which works the same way is referenced, but not demonstrated.

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question