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 are Dynamic SQL statements?

Answer Posted / naresh

Basically Dynamic SQL means, you'll construct a SQL
statement dynamically while runtime and run it.

Why this needed: Since the stored database objects
(Procedures and Functions and others) will be compiled while
creating and stored inside a database.so everything has been
checked already. so whenever you make a call to these
programs they will directly run withou compiling second time.
since it runs without compiling you cannot use DDL commands
inside a stored program.

So to avoid this you can directly mention Execute Immediate
keywords in front of a SQL query dynamically in your
block.so that it'll work this time.

Hope this helps.

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is snowflake sql?

1010


What sql database should I use?

1064


How to change sql*plus system settings?

992


What if we write return in procedure?

1331


What is orm in sql?

992


What are the advantages of stored procedure?

945


what are the 'mysql' command line options? : Sql dba

1013


Can a trigger call a stored procedure?

1000


What trigger means?

926


What are different sql data types?

951


what is oracle database ? : Sql dba

966


What is null in pl/sql?

1021


Explain the purpose of %type and %rowtype data types?

873


Can cursors be part of a trigger body?

1583


What kind of join is join?

903