Yes, I was thinking about using a structure but I am unsure of the best way to 
do a comparison. Wouldn't this mean having to a field by field comarison or is 
there a better way? I was wondering if anybody had created a custom tag to do 
just this sort of thing.

>Should be easy enough and no doubt several way s to achieve this....both in
>CF Code and in SQL.  One way would be to load the records at page load into
>a structure and then on submit comparing both the pre-edited and post edited
>form struct to see what has changed etc...
>
>
>
>-----Original Message-----
>From: Andy Mcshane [mailto:[EMAIL PROTECTED] 
>Sent: 26 May 2006 10:25
>To: CF-Talk
>Subject: Only update DB if data has changed?
>
>Hi all, does anybody have any ideas how I could best implement the
>following;
>
>I have a page that loads anything up to about 30 individual records at a
>time. Each record consists of 17 fields of data. All the records are
>displayed on the page to give the user the option of editing any individual
>field. When the user then submits the page I need to be able to work out
>which records have had data changed and only do database updates for those
>specific records. Having an individual submit for each record is not an
>option, the whole page must be submitted as one but only records that have
>changed should be updated. Can anybody suggest a method for doing this?

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:241544
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

Reply via email to