Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsGeneralPHPASPPerlColdFusionFlashHTML, CSS, ScriptsBrowsers

Webmaster Forum / ColdFusion / Advanced Techniques / April 2007



Tip: Looking for answers? Try searching our database.

Save Query Results

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
gill1723 - 26 Apr 2007 20:56 GMT
Every time this page is called it run the component is there a way to save the
results of the component when it runs the first time?  I need to hold it and
compare the results to a form field.  The only thing is everytime the hit the
submit button it runs the query again and give different results.

<cfinvoke component="swabl/IdentityAnswers" method="IDQuestions"
returnvariable="getItems">

<form name="form1" action="" method="post">
<input name="question" type="hidden" value="<cfoutput
query="getItems">#question#</cfoutput>" />
<input name="answer" type="hidden" value="<cfoutput
query="getItems">#answer#</cfoutput>" />
</form>
Ian Skinner - 26 Apr 2007 21:08 GMT
returnvariable = "session.getItems" OR returnvariable =
"application.getItems" OR returnvariable = "server.getItmes" Depending
on where you would like to persist the results.  The documentation has
lots of information on the persistent variable scopes.
gill1723 - 26 Apr 2007 22:08 GMT
so if I use returnvariable = "session.getItems", do I have to set up sometype of session?
Dan Bracuk - 27 Apr 2007 04:47 GMT
You have to enable sessions in your application.cfm/cfc file.
Ian Skinner - 27 Apr 2007 15:16 GMT
> You have to enable sessions in your application.cfm/cfc file.

I would like to clarify that the <cfapplication...> tag does not HAVE to
be in the application.cfm/cfc files.  Those locations are a very
convenient place to put the tag, but the tag can be coded anywhere.  It
just has to be in any file that one wants to connect to a given
application on a server as defined by the name parameter in the
<cfapplication...> tag.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.