Re: Handling a VO parsed from Flex to CF

2008-10-07 Thread Simon Bailey
Hi Tom, Ok I sussed it, I have discovered that arguments.aRecord.course_results[i] was not actually passing the Object, to be honest I have no idea what it was passing but whatever it was passing it was wrong. After some further debugging and dumping I have now found that the Object is

Re: Handling a VO parsed from Flex to CF

2008-10-07 Thread Tom Chiverton
On Tuesday 07 Oct 2008, Simon Bailey wrote: Unable to invoke CFC - The value coldfusion.runtime.TemplateProxy cannot be converted to a number. If you CFDUMP or debug just before the loop, what is the value of 'i', 'arguments.aRecord.course_results' and 'arguments.aRecord.course_results[i]' ?

Re: Handling a VO parsed from Flex to CF

2008-10-07 Thread Simon Bailey
Unable to invoke CFC - The value coldfusion.runtime.TemplateProxy cannot be converted to a number. However I am 100% that all the passed elements are of correct data types? Is this throwing the error up think i.e. aRecord is a VO and course_results is the array of VO's?

RE: Handling a VO parsed from Flex to CF

2008-10-07 Thread Paul Kukiel
PM To: cf-talk Subject: Re: Handling a VO parsed from Flex to CF Unable to invoke CFC - The value coldfusion.runtime.TemplateProxy cannot be converted to a number. However I am 100% that all the passed elements are of correct data types? Is this throwing the error up think i.e. aRecord is a VO

RE: Handling a VO parsed from Flex to CF

2008-10-07 Thread Paul Kukiel
To: cf-talk Subject: Re: Handling a VO parsed from Flex to CF Unable to invoke CFC - The value coldfusion.runtime.TemplateProxy cannot be converted to a number. However I am 100% that all the passed elements are of correct data types? Is this throwing the error up think i.e. aRecord is a VO

Re: Handling a VO parsed from Flex to CF

2008-10-07 Thread Brian Kotek
parsed from Flex to CF Unable to invoke CFC - The value coldfusion.runtime.TemplateProxy cannot be converted to a number. However I am 100% that all the passed elements are of correct data types? Is this throwing the error up think i.e. aRecord is a VO and course_results is the array of VO's

Handling a VO parsed from Flex to CF

2008-10-06 Thread Simon Bailey
Hi all, I have a relatively straight forward question I was wondering if people may shed some light on. I am passing a value object from Flex to CF which has a course_id, course_name and an Array of values. In my method in my cfc I would like to update one mysql table with the course_id

Re: Handling a VO parsed from Flex to CF

2008-10-06 Thread Tom Chiverton
On Monday 06 Oct 2008, Simon Bailey wrote: I have a relatively straight forward question I was wondering if people may shed some light on. I am passing a value object from Flex to CF which has a course_id, course_name and an Array of values. In my method in my cfc I would like to update one

Re: Handling a VO parsed from Flex to CF

2008-10-06 Thread Simon Bailey
Ok hands up I sounded like a dumb a$$. Its the loop query aspect I had an issue with and thought I would test the water if I was on the right logic from the get go before I questioned the below code as it is failing somehow: cfquery name=qResult datasource=#dsn#

Re: Handling a VO parsed from Flex to CF

2008-10-06 Thread Brian Kotek
For starters the CF drivers won't let you attempt to execute multiple statements in a single cfquery like that (though I believe this can be changed with connection string arguments). Try moving the loop outside of the cfquery tags so that each query runs within a single cfquery tag. On Mon, Oct

Re: Handling a VO parsed from Flex to CF

2008-10-06 Thread Justin Scott
For starters the CF drivers won't let you attempt to execute multiple statements in a single cfquery like that (though I believe this can be changed with connection string arguments). Try moving the loop outside of the cfquery tags so that each query runs within a single cfquery tag. Sure it

Re: Handling a VO parsed from Flex to CF

2008-10-06 Thread Brian Kotek
Well it definitely doesn't in MySQL but obviously YMMV depending on platform. On Mon, Oct 6, 2008 at 11:49 AM, Justin Scott [EMAIL PROTECTED]wrote: For starters the CF drivers won't let you attempt to execute multiple statements in a single cfquery like that (though I believe this can be

Re: Handling a VO parsed from Flex to CF

2008-10-06 Thread Justin Scott
Brian Kotek wrote: Well it definitely doesn't in MySQL but obviously YMMV depending on platform. Well, I can't help it that MySQL is an inferior platform. ;) /me runs away in a zig-zag pattern while ducking and covering his head. -- Justin Scott, http://www.tlson.com/

Re: Handling a VO parsed from Flex to CF

2008-10-06 Thread Brian Kotek
Like I said, you can enable this in the JDBC connection string. It is simply off by default due to the security ramifications of allowing multiple statements by default. On Mon, Oct 6, 2008 at 1:58 PM, Justin Scott [EMAIL PROTECTED] wrote: Brian Kotek wrote: Well it definitely doesn't in

Re: Handling a VO parsed from Flex to CF

2008-10-06 Thread Simon Bailey
Hey guys thanks for that, @brian I tried your suggestion to no avail: cfloop array=#arguments.aRecord.course_results# index=i cfquery name=qResult datasource=#dsn# UPDATE c_results SETrating =

Re: Handling a VO parsed from Flex to CF

2008-10-06 Thread Brian Kotek
Well are you getting an error message? You can use Firebug or Charles to see the server's response to the AMF request. You can also check the server logs, or even add a try catch and save the error to a text file or PDF so that you can see it. On Mon, Oct 6, 2008 at 7:04 PM, Simon Bailey [EMAIL