Original Post
I have a oracle machine I am using and have writting something that gets a list of each table in a schema, then starts with the first table, gets a list of columns, goes to the first column of that table and is suppose to get the data in it, then go to the second column, ect till the table is done then move on to the next table and start all over. So far I can get a list of tables and a list of columns in each table, BUT I cannot figure out a SELECT Statement that A) allows me to use varaibles instead of names IE curr_table = the current tables name curr_column = current columns name select curr_column from curr_table OR B) I have tried Select (Select column_name from all_tab_cols where table_name=curr_table_name and column_name= curr_col_name) from (Select table_name from dba_tables where table_name=curr_table_name) My problem with this is that the tables I am calling are in a schema. My usual call statements are select * from schema.table1 or along those lines If my first large select statement is working then it is coming out to be select column1 from table1 and I cannot figure out how to add a schema. infront of the table1. So it would say Select column1 from schema.table1 Any help?