How to perform a loop through all tables in pl/sql?
Answers were Sorted based on User's Feedback
Answer / chandrakant rathod
We can get all tables for particular instance using below block .
SET SERVEROUTPUT ON;
begin
for rec in (select object_name from user_objects where object_type='TABLE')
loop
dbms_output.put_line('TABLE'||rec.object_name);
end loop;
end;
/
| Is This Answer Correct ? | 6 Yes | 0 No |
We can use user_tables view of data dictionary.
create a cursor based on query
select * from user_tables and then use use this cursor
in for loop
| Is This Answer Correct ? | 3 Yes | 4 No |
Answer / highness
I got a lot of definitions for this but i thing this is right
A compiled plsql procedure
stands for a stored procedure...
check out this
| Is This Answer Correct ? | 1 Yes | 2 No |
Answer / mahesh gulati
select * from sysobjects where type = 'u'
| Is This Answer Correct ? | 3 Yes | 7 No |
What is a pdo connection?
What is meant by Materialized view?
2 Answers iGate, Marlabs, Polaris,
What is update query?
What is set serveroutput on in pl sql?
What is transaction control language (tcl)?
What is the syntax and use of the coalesce function?
function can return multiple value?how give give sample coding
2 Answers 3i Infotech, CTS, Excelity Global, UHG,
What is data modelling in sql?
what is union? : Sql dba
What does sign mean sql?
What is Overloading of procedures ?
How many row comparison operators are used while working with a subquery?
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)