> Now, the stored procedure that provides the engine of this search has a
bunch > of conditional logic that leads to a different SQL statement based
on the
> options that the user has picked.
Robert,
As per some other thread a couple of days ago, building the SQL statement
dynamically has one big advantage - it can very drastically simplify your
code. But it also has one drawback - if your stored procedure doesn't have
the SQL query hard-coded, the DBMS cannot store an optimised query plan for
that query (i.e. decide which indexes to use, which order to read the tables
etc) and has to work out a query plan on the fly every time it's called. So
if you're trying to get the fastest solution, I suspect you already have it.
Nick
**********************************************************************
Information in this email is confidential and may be privileged.
It is intended for the addressee only. If you have received it in error,
please notify the sender immediately and delete it from your system.
You should not otherwise copy it, retransmit it or use or disclose its
contents to anyone.
Thank you for your co-operation.
**********************************************************************
------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.