Hi,
I have a problem with the below CFQuery. I am stuck - please help!!!
**********
Here is the query
<!--- get this cat, all above and all one level below --->
<cfset cattree = "">
<cfif IsDefined("ID"
>
<cfset thisone = result.category>
<cfelse>
<cfset thisone = category>
</cfif>
<cfquery name="allbelow"
DBTYPE="dynamic"
maxrows = "1"
connectstring = "Driver={SQL Server};Server=sql-001.affinity.com;Database=db70053;Uid=collec12;Pwd=7sychedelic;">
SELECT ParentID, ID FROM ArticleCategories WHERE ParentID = #thisone#
</cfquery>
*******************
The error I receive is :
ODBC Error Code = 37000 (Syntax error or access violation)
[Microsoft][ODBC SQL Server Driver][SQL Server]Line 1: Incorrect syntax near '='.
The error occurred while processing an element with a general identifier of (CFQUERY), occupying document position (100:1) to (103:115).
Any help would be really appreciated.
Cheers
NICK
I have a problem with the below CFQuery. I am stuck - please help!!!
**********
Here is the query
<!--- get this cat, all above and all one level below --->
<cfset cattree = "">
<cfif IsDefined("ID"

<cfset thisone = result.category>
<cfelse>
<cfset thisone = category>
</cfif>
<cfquery name="allbelow"
DBTYPE="dynamic"
maxrows = "1"
connectstring = "Driver={SQL Server};Server=sql-001.affinity.com;Database=db70053;Uid=collec12;Pwd=7sychedelic;">
SELECT ParentID, ID FROM ArticleCategories WHERE ParentID = #thisone#
</cfquery>
*******************
The error I receive is :
ODBC Error Code = 37000 (Syntax error or access violation)
[Microsoft][ODBC SQL Server Driver][SQL Server]Line 1: Incorrect syntax near '='.
The error occurred while processing an element with a general identifier of (CFQUERY), occupying document position (100:1) to (103:115).
Any help would be really appreciated.
Cheers
NICK