First thing that I see is that you are not returning anything from
your function.

You have
<cffunction name="getWeekSessionSummary" access="remote">

And it should be
<cffunction name="getWeekSessionSummary" access="remote"
returnType="query">

--- In [email protected], "kjlinboomer"
<[EMAIL PROTECTED]> wrote:
>
> hi Jeremy -- thanks -- below is the CF component I am trying to
access.  
> 
> //----------------------------------------------------------------
> <cffunction name="getWeekSessionSummary" access="remote">
> 
>       <cfargument name="productorialID" type="string" required="yes">
>       <cfargument name="action" type="string" required="yes">
>       <cfargument name="startdate" type="string" required="yes">
>       <cfargument name="enddate" type="string" required="yes">
>       
>       <cfset today = Now()>
>       <cfset today_fmt = DateFormat( today, 'yyyy-mm-dd' )>
>       <cfset yesterday = DateAdd( 'd', -1, today )>
>       <cfset yesterday_fmt = DateFormat( yesterday, 'yyyy-mm-dd' )>
>       <cfset oneweekago = DateAdd( 'd', -6, today )>
>       <cfset oneweekago_fmt = DateFormat( oneweekago, 'yyyy-mm-dd' )>
> 
>       <cfquery name="getAggSessions" datasource="statistics">
>               SELECT logcache_datestamp, logcache_event_count AS count
>               FROM syscache
>               
>               <cfif arguments.action neq "">
>                       WHERE (logcache_datestamp BETWEEN '#oneweekago_fmt#' AND
'#today_fmt#')
>                       AND logcache_productorialid = 
> '#arguments.productorialID#' 
>                       AND logcache_event_type = 'sessionsCount'
>               <cfelse>
>               
>                       <cfif arguments.startdate neq "" AND arguments.enddate 
> neq "">
>                               WHERE (logcache_datestamp BETWEEN '#startdate#' 
> AND '#enddate#')
>                               AND logcache_productorialid = 
> '#arguments.productorialID#' 
>                               AND logcache_event_type = 'sessionsCount'
>                       <cfelse>
>                               WHERE logcache_productorialid = 
> '#arguments.productorialID#'
>                               AND logcache_event_type = 'sessionsCount'
>                       </cfif>
>               
>               </cfif>
>               GROUP BY logcache_datestamp
>       </cfquery>
> 
>       <cfset count = "#getAggSessions.count#">
> 
>       <cfif count NEQ "">
>               <cfreturn "#getAggSessions#">
>       <cfelse>
>               <cfreturn "n/a">
>       </cfif>
> 
> </cffunction>
> 
> // -------------------------------------------------------------------
> 
> I have added to the white list as descibed in my previous post and
> then I am just trying to add a dataservice using the data panel in
> flex builder 1.5.  Once I select the service name from the drop down
> it complains that it cant connect.
> 
> Thanks Again!
> 
> 
> --- In [email protected], "Jeremy Rottman" <[EMAIL PROTECTED]>
> wrote:
> >
> > Can you post you post your flex/cf code so we can look at it.  
> > 
> > --- In [email protected], Keith Lindenboom
> > <[EMAIL PROTECTED]> wrote:
> > >
> > > Hi All,
> > > 
> > > I am trying to set up some CF components to be used as web services
> > through
> > > flex.  I have added a node to the named section web-service proxy
> > node of
> > > the flex config file as seen below:
> > > 
> > >   <named>
> > >               <service name="reportingService">
> > >                
> > <wsdl>http://192.168.168.1/keith/components/reporting.cfc?wsdl
> > > </wsdl>
> > >                  <endpoints>
> > >                         <!-- actual url to use when accessing the
> > named web
> > > service -->
> > >                
> > <endpoint>http://192.168.168.1/keith/components/reporting.cfc
> > > </endpoint>
> > >                 </endpoints>
> > >                 <!-- define a web service which may be referenced by
> > name
> > > from mxml -->
> > >                 <!-- <service name="service"> -->
> > >                     <!-- enables use of custom fault code on the
> > client for
> > > handling authentication failures -->
> > >                     <!--
> > > <use-custom-authentication>false</use-custom-authentication>
> > > -->
> > >                     <!-- wsdl location for the named service -->
> > >                     <!--
> > > <wsdl>http://localhost:8100/flex/flex-proxy/servicename?wsdl
> > > </wsdl> -->
> > >                     <!-- endpoints for the named web service -->
> > >                     <!-- <endpoints> -->
> > >                         <!-- actual url to use when accessing the
> > named web
> > > service -->
> > >                         <!-- <endpoint>
> > > http://localhost:8100/flex/flex-proxy/servicename</endpoint> -->
> > >                     <!-- </endpoints> -->
> > >                     <!-- user-name and password to use when
> > accessing this
> > > web service -->
> > >                     <!-- <run-as user="user" password="pwd"/> -->
> > >                     <!-- Adds the service's wsdl and endpoints
to the
> > > unnamed whitelist.  If false, these can never be used unnamed -->
> > >                     <!-- This should be set to false if using web
> > > application security with this named service -->
> > >                    
> > <!--<allow-unnamed-access>true</allow-unnamed-access>-->
> > > 
> > >               </service>
> > >             </named>
> > > 
> > > I am having trouble connecting to the service in flex builder (it
> keeps
> > > failing).  I know that the path and everyhting is correct and I can
> > invoke
> > > the components directly with CF.  I have tried restarting the
> > service and
> > > the when i compile the file i get a "500 internal server error" 
> Anybody
> > > else run into this problem?
> > > 
> > > Any help would be greatly appreciated!
> > > 
> > > Thanks,
> > > 
> > > Keith
> > >
> >
>






--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to