Difference between inline query and stored procedure?

Answer Posted / sudama maharana

1. Stored procedure is loaded to database once it compiled, but inline queries are not loaded in to server. So, Stored procedure is in compiled form.

2. As Stored procedure is in compiled form, so in each calling to it, it takes less time than inline queries. Because in Stored procedure we are passing only the names, but in inline query we are passing the whole query.

3. Stored procedures are compiled only once and in each calling its only executing the query. But inline queries are compiled & executed in each calling. So, in stored procedure network Traffic is less.

4. In stored procedure, we can pass parameters . But in inline query we can't pass.

Thanks

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is sql and db2?

538


how can you create an empty table from an existing table? : Sql dba

665


What is data profiling in sql?

521


When sql appeared?

625


What does dml mean?

550






When a dml statement is executed, in which cursor attributes, the outcome of the statement is saved?

642


How can I tell if sql is running?

595


Which join is like an inner join?

531


What is the difference between microsoft sql and mysql?

514


Explain raise_application_error.

646


what is the difference between myisam static and myisam dynamic? : Sql dba

590


what is the use of set statement in tsql? : Transact sql

538


Where the sql database files are stored?

500


What is the difference between the conventional and direct path loader? : aql loader

658


Why coalesce is used in sql?

475