Click to See Complete Forum and Search --> : how to input a tablename thru script


rratheesh
03-21-2007, 04:36 AM
hi,
I have a script which dispalys the fields which is mentioned there in the table.(ie) its hardcoded.but what i need is the script should be in a generalised format so that when we give any table_name it should populate the values of those table.How can it be done

it should ask for the input of table name (ie)table name should be inputted manually.
and then it should populate the corresponding tablename values


Thanks
R.Ratheesh

ebrian
03-21-2007, 07:27 AM
Assuming you want to run this query thru SQL*Plus, you can consider Communicating with the User (http://download-east.oracle.com/docs/cd/B19306_01/server.102/b14357/ch5.htm#sthref1089).

rratheesh
03-21-2007, 10:15 AM
Assuming you want to run this query thru SQL*Plus, you can consider Communicating with the User (http://download-east.oracle.com/docs/cd/B19306_01/server.102/b14357/ch5.htm#sthref1089).
thanks ebrian.
now what i have to do is i can select like select * from tab;which contains all table name which can be matched with the table name which user is entering.how to get this table name from tab as one by one.what iam trying to do is if the user entering table name and the table name which is there in database matches .then the particular table should display the fields.is this ok or any modifications has to be made

patel_dil
03-22-2007, 10:19 PM
For table columns, use all_tab_columns.