[thelist] Coldfusion/SQL:queries:maxrows

Seamus Campbell cf at boldacious.com
Mon Sep 17 07:12:52 CDT 2001


<cfquery name="test" datasource="#request.DSN#">

SELECT TOP 1 (productID), ProductDesc

FROM    tblproduct

</cfquery>


Above is sql - this is quicker I believe
I think it is because the sql only searches the top 1 row
while CF searches the whole database then returns 1 row (I think)

Seamus






More information about the thelist mailing list