Whats more efficient for a recordsource....

C

Chris Strug

Whats more efficient for a recordsource to a form / combo box / whatever, a
view or a stored procedure.

Assuiming that its a case of a simple select statement, which should I
choose any why?

Thanks

Chris.
 
M

Mike Painter

Chris Strug said:
Whats more efficient for a recordsource to a form / combo box / whatever, a
view or a stored procedure.

Assuiming that its a case of a simple select statement, which should I
choose any why?
If it's a query then you have to select the items you will use on the forms/
reports etc.
If the form is based on a single table then there may or may not be a more
efficient way to display information.

With a five or six year old machine I perceive nothing different between a
query or a table with 25k records.
 
V

Vadim Rapp

CS> Whats more efficient for a recordsource to a form / combo box /
CS> whatever, a view or a stored procedure.

CS> Assuiming that its a case of a simple select statement, which
CS> should I choose any why?

If it's sql server 2000, then neither. Just that plain sql statement. sql
server 2k caches execution plans and will not recompile (see "Execution Plan
Caching and Reuse" in BOL). Your benefit is avoiding an extra object to
maintain.

The only consideration in favor of view or s.p. is that they open the
possibility of quick fixes on the server instead of patching the ADP and
redistributing it to the users.


Vadim
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top