Subject Re: Stored Procedures - Including variables to form part of the query
Author russx2
Thanks for the advice Helen. Not entirely sure what you mean by this
though:

> What you can do is call the selectable procedure with an ORDER BY
clause
> and a WHERE clause, if you don't want to do the WHERE via
parameters. It's
> slow on the server side, since the entire procedure will have to
execute
> before the sorting can begin, but it might be acceptable if the
unmodified
> output set is small.

Do you mean to perform a select from the SP (much like a view) whilst
specifying the where/order clauses? If so, yes, I can see why this
would be slow.

As a general rule though, SPs are more efficient than performing the
query directly from the client yes?

I think, as you suggested, I will go with the view option in this
case. I was trying to restrict client access to the db through the use
of SPs only but a view seems a good compromise given the requirements.

Russ