So I'm trying to learn the whole OO stuff behind CF..
I've got a user gateway, dao, bean created.. but something is up with
one of the functions...
I'm creating the gateway in the application.cfc
<cfset application.userGateway = createObject("component",
"cfc.users.UserGateway").init( DSN = application.DSN ) />
my Gateway works here..
<cfset foo = application.userGateway.getUser(emplid = '0012345') />
I can see in the debug where it's called and ran...
qUser (Datasource=j00mamma, Time=539ms, Records=1) in
C:\JRun4\servers\cfusion\cfusion-ear\cfusion-war\qRunner\cfcs\users\UserGateway.cfc
@ 16:08:22.022
SELECT
emplid,isadmin
FROM
users_tbl
WHERE
emplid = ?
AND
isactive = 1
Query Parameter Value(s) -
Parameter #1(cf_sql_varchar) = 0012345
Okay, so that's all cool.. so why is THIS not working????
<cfset qGroupsX = application.userGateway.getGroupsForUser(emplid = '0012345')>
CF just stops processing.. anything that should have followed the call
is not there.. so I look in my GateWay and here's my query...
<cffunction name="getGroupsForUser" access="public" output="false"
returnType="query" hint="returns a recordset of groups per user">
<cfargument name="emplid" default="" required="true">
<cfset var qGroups = "" />
<cfquery name="qGroups" datasource="#variables.DSN#">
select gt.group_id, gt.group_name
from groups_tbl gt
left join group_user gu
on gt.group_id = gu.group_id
and gu.emplid = <cfqueryparam cfsqltype="cf_sql_varchar"
value="#arguments.emplid#">
</cfquery>
<cfreturn qGroups />
</cffunction>
Nothing fancy... am I'm missing something here? Why isnt this working?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to
date
Get the Free Trial
http://ad.doubleclick.net/clk;160198600;22374440;w
Archive:
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:300343
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4