Skip to main content
Known Participant
August 3, 2008
Question

viewing structures made in a coldfusion component

  • August 3, 2008
  • 2 replies
  • 395 views
i am trying to load data into a database using a component made in the extensions wizard of eclipse. when i do an insert using a cfquery tag in the main page, it works. using the cfc it fails out with a mysql error of cannot do update because of a foreign key constraint, leading me to believe the data isnt making it to mysql. I try to dump the data from the user variable in the main page, but it takes me to the coldfusion administrator and shows me the function info for the cfc, not the struct values. Here is the related code from the main page and all related cfcs. any help is greatly appreciated!
This topic has been closed for replies.

2 replies

Known Participant
August 4, 2008
Thank you very much for your help--changed the <cfreturn this> to <cfreturn "mystructure">, this works!
Prasanth_Kumar_S
Inspiring
August 3, 2008
Hi,
You cannot directly call a CFC and see the values. Instead, create a object of the CFC and pass the required parameters through a cfm file. But here, as you are just inserting, you will not be able to see the values. So do a cfdump and a cfabort before the insert to see which all values are being passed to the DB.

-Prasanth
BKBK
Community Expert
Community Expert
August 3, 2008
I missed <cfreturn this>. It will work if you do it along these lines.