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...


What is dynamic SQl and how you will create and execute
dynamic sql?

Answers were Sorted based on User's Feedback



What is dynamic SQl and how you will create and execute dynamic sql?..

Answer / raksha

Dynamic SQL enables you to write programs that reference SQL statements whose full text is not known until runtime.

Below is the way to execute dynamic sql

EXECUTE IMMEDIATE 'SELECT d.id, e.name FROM dept_new d, TABLE(d.emps) e -- not allowed in static SQL
-- in PL/SQL
WHERE e.id = 1'

Is This Answer Correct ?    5 Yes 0 No

What is dynamic SQl and how you will create and execute dynamic sql?..

Answer / ravi singh

Dynamic SQL enables you to executes your SQL statement at run time on the basis of different conditions. They can be executed with the help of creating SQLs at run time. you can store your where clause or sql statements in variables and on the basis of requirements you can execute them.
Dynamic SQL comprises reference cursors.
for ex: open cursor for select a,b,c from table_name;

execute immediate 'select a,b from table_name'

you can store the result set into variables too.

Is This Answer Correct ?    2 Yes 0 No

Post New Answer

More SQL PLSQL Interview Questions

How do I count rows in sql query?

0 Answers  


how can stop the sequence with mention the max value and with out mention the max value

1 Answers   Zensar,


Do foreign keys improve performance?

0 Answers  


How will we see framework of a table?

2 Answers   Accenture,


How to change a value of the field ‘salary’ as 7500 for an employee_name ‘john’ in a table employee_details?

0 Answers  


What do you think about pl/sql?

0 Answers  


What is Referential Integrity?

3 Answers   IBM,


How do you display "13th of November, 17 days left for month end" without hardcoding the date.

3 Answers  


What is native sql query?

0 Answers  


what are the advantages of mysql in comparison to oracle? : Sql dba

0 Answers  


State the difference between implict and explict cursor's?

7 Answers   CTS,


Can primary key be changed?

0 Answers  


Categories