Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

how to create table with in the procedure or function?

Answer Posted / vipin kumar

If we need to create a table in the stored procedure then we need to use the execute immediate and then the string ' create table emp(name varcha2(1000))'



Other then this if we need to create a table which will just store the records (collections) then it will be like

--declare a row first
type employee is record
(Emp_name varchar2(100),
emp_id number);

--
-- Create a table now
--
type tab_employee is table of employee
index by binary_integer;

Is This Answer Correct ?    4 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is trigger in flip flop?

1007


Can we use ddl statements in stored procedure sql server?

1012


How is data stored on a disk?

1036


How do you modify a column in sql?

999


Can we use commit inside a trigger?

1094


what is a primary key? : Sql dba

1034


What is pl/sql table? Why is it used?

1045


what are the advantages and disadvantages of cascading style sheets? : Sql dba

1060


How to write html code in pl sql?

1119


How subquery works in sql?

1070


What is %type in sql?

968


what are dynamic queries in t-sql? : Transact sql

1024


How do I truncate a sql log file?

1075


What are character functions?

1087


Is it possible to Restore a Dropped Table using Rollback Command in Oracle SQL Plus ?

1227