I get a weird error with structexists in that if the key doesn't exists (which
should return false) it breaks! see code and error messgae below:

code:

....
<cfif not StructKeyExists(profile, "loyalty")>
<cfscript>
fUpdateSession = true;

structLoyalty = StructNew();
.....


Error message:

Error Occurred While Processing Request



The error occurred in
C:\workspace\xyzMX\wwwroot\framework\loyaltythepro file.cfm: line 101
Called from C:\workspace\xyzMX\wwwroot\index2.cfm: line 1659
Called from C:\workspace\xyzMX\wwwroot\index2.cfm: line 1
Called from C:\workspace\xyzMX\wwwroot\index.cfm: line 1

99 : <cfset profile = StructNew()>
100 : </cfif>
101 : <cfif not StructKeyExists(profile, "loyalty")>