Azhar Azhar - 1 year ago 68
SQL Question

Query vs Stored procedure; difference between two approaches

I am developing a web page for search. I have two options to build this page

  1. To build the query on page according to parameter enter by the user and send it to server.

  2. To send parameters to stored procedure and build query there and get it executed.

I want to know that which approach I should adopt and why.

I want to know the advantages or disadvantages of both approaches.

Answer Source

You can take idea from following links:

Ad hoc queries vs stored procedures vs Dynamic SQL

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download