Running Coldfusion Enterprise Server 5.0, our staging environment is allowing
the following type query:

<cfquery name="rsCategories" datasource="Northwind"
cachedwithin=#CreateTimeSpan(1,0,0,0)#>
SELECT CategoryID, CategoryName FROM Categories
WHERE CategoryID = <CFQUERYPARAM value='#myValue#'>
</cfquery>

In production, the above type query gives an error, complaining of the
CFQUERYPARAM being used with the cachedwithin attribute. According to the
documentation, it should give an error, so how come it does not give an error
in staging? If we make a change to the query in staging, such as a syntax
error, it does reflect the changes in staging, which means it's not caching the
page from an earlier version when the CFQUERYPARAM was not included.

Any help would be greatly appreciated. Thank you!