cfqueryparam
I am trying to lock down the queries on the site I am working on with cfqueryparam and while the basics are pretty straight forward, I am not quite sure how to handle a query like this. SELECT TOP 3News.newsTitle, News.newsBriefDesc, News.newsID, NewsBySection.precedence, News.startDate, News.endDate, News.newsFullBody FROMNews LEFT OUTER JOIN NewsBySection ON News.newsID = NewsBySection.newsID WHERE ((NewsBySection.sectionID = '13') AND (News.startDate = '#daterequestAdd#') AND (News.archive = 0)) AND ((News.endDate = '#daterequestAdd#') AND (NewsBySection.sectionID = '13') AND (News.archive = 0) ) ORDER BYNewsBySection.precedence ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;203748912;27390454;j Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:310019 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: cfqueryparam
WHERE NewsBySection.sectionID = '13' !--- is this a char/varchar? --- AND News.startDate = cfqueryparam value=#daterequestAdd# cfsqltype=cf_sql_date / AND News.endDate = cfqueryparam value=#daterequestAdd# cfsqltype=cf_sql_date / AND News.archive = 0 * depending on your datatype, that cfsqltype might need to be changed to cf_sql_timestamp On Thu, Jul 31, 2008 at 12:02 PM, Robert Newhart [EMAIL PROTECTED]wrote: The NewsBySection.sectionID = '13' is an INT in the table. ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;203748912;27390454;j Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:310021 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Multiple Job Histories
I am building a membership app which requires multiple job histories. I have tried to build the section using the CFPanel Tabs function as well as with Spry panels. Ideally, the client wants to be able to have unlimited job histories but is fine with a limited amount. I am looking for a way to accomplish the former as well as trying to accomplish the later. I wanted to use a CFLOOP over the basic form rather than repeating the form in hard coded fashion. Additionally, how can I save the data in the form so I can do multiple inserts into a database table? I have a table with all the form fields and was going to use the UserID and JOIN the information for later retrieval. Additionally, I am using a struc to populate the form fields if the user has already filled out the form and wants to return to it to update information. Here are links to the CF Panel version and the Spry version. http://www.visualeffectssociety.com/membership (CF Version) http://www.visualeffectssociety.com/membership/index_spryTabbed.cfm ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;203748912;27390454;j Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:309180 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: Multiple Job Histories
William, when you say the method used earlier Im not really clear on what you mean. Additionally, I don't have any real Javascript experience. I like the method that was being used earlier. Use javascript to 'insertRow', so the user can create as many histories as they need. Then when CF receives the file you can do a 'while' loop that only inserts the work history data as the fields exist in the form element. William -- William E. Seiter ColdFusion Programmer / Web Developer Free Website Trade Publication Website Magazine Be sure to answer all of the questions on the subscription form, small price to pay for the loads of excellent content this magazine offers to Web Professionals for FREE!! Have you ever read a book that changed your life? Go to: www.winninginthemargins.com Use PassKey: GoldenGrove You'll be glad you did. I am building a membership app which requires multiple job histories. I have tried to build the section using the CFPanel Tabs function as well as with Spry panels. Ideally, the client wants to be able to have unlimited job histories but is fine with a limited amount. I am looking for a way to accomplish the former as well as trying to accomplish the later. I wanted to use a CFLOOP over the basic form rather than repeating the form in hard coded fashion. Additionally, how can I save the data in the form so I can do multiple inserts into a database table? I have a table with all the form fields and was going to use the UserID and JOIN the information for later retrieval. Additionally, I am using a struc to populate the form fields if the user has already filled out the form and wants to return to it to update information. Here are links to the CF Panel version and the Spry version. http://www.visualeffectssociety.com/membership (CF Version) http://www.visualeffectssociety.com/membership/index_spryTabbed.cfm ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;203748912;27390454;j Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:309183 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: Multiple Job Histories
William, Thank you for your help. I will do some homework to figure out how to get this done, but you have given me a starting point. http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:57026#309182 William, when you say the method used earlier Im not really clear on what you mean. Additionally, I don't have any real Javascript experience. ~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;203748912;27390454;j Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:309190 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4