> From: David Fafard
>
> So of I use:
>
> select x,y,z from tbl where id=1
> select x,y,z from tbl where id=2
> select x,y,z from tbl where id=3
>
> where id would be a dynamic variable,
> I would not get any benefit in using cached query
> but would see a benefit from cfqueryparam ?

How many variations on ID?

How much data is coming back?

In this instance, I'd use a CFQUERYPARAM as you know that the ID is
changing

BUT - if you only have 3 variations on ID, then it might be worth
caching the query

Next you get into the question of HOW to cache the query

If you use CACHEDWITHIN or CACHEDAFTER then you can't use CFQUERYPARAM

But if you store the results into another scope, like Application, then
you can use CFQUERYPARAM to your heart's content :)
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to