That made me think about Form.FormFields. I suppose I could just loop over that list or do a cfif ListFind()...
On 3/30/06, Dawson, Michael <[EMAIL PROTECTED]> wrote: > > This also came to mind. Create a variable, in your object, that stores > a list of fields that were updated, or updateable. > > On the larger form, you would specify all fields, or none to default to > all fields. On the smaller form, you specify only the fields that > should be updated. > > Then, in you DAO, you loop over the list (or do some CFIFs) that > determine which fields you add to your SQL UPDATE statement. > > I think this is a bit of a kludge, but it's workable. > > M!ke > > -----Original Message----- > From: Matt Williams [mailto:[EMAIL PROTECTED] > Sent: Thursday, March 30, 2006 2:22 PM > To: CF-Talk > Subject: Re: OOP/CF - Update Function in a DAO > > Mike, I thought of that too. It would probably work. The issue I have > with it is if a field were to get added at some point, I'd have to make > sure every possible form got that field added. > > Keep thinking. I know there has to be an easier way. I fear it involves > mucho 'if' statements. > > Matt > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:236611 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

