The customer would like to have versions of the product that he could print out. I'm not sure I see an easy way of doing this with the data stored like this. Then again its Monday morning and I'm not firing on all cylinders yet. :-\
On Mon, Apr 7, 2008 at 10:49 AM, Matt Williams <[EMAIL PROTECTED]> wrote: > This type of data logging is quite common. One way to do it is before > doing the update, get the record again from the db. Compare it to the > form data. Another way is to have the form send a duplicate set of > form fields named something like "orig_productName". Or you could even > be fancy with some javascript to make a list of the fields changed > when they are changed. > > For tracking what was changed, you don't really need the XML, you can > do it with an additional table. You could have a table with something > like > changed_ID | changed_table | changed_field | orig_value | new_value. > A sample record would be > 1234 | 'tbl_product' | 'product_name' | 'my widget' | 'my cool widget' > > Matt > > On Mon, Apr 7, 2008 at 10:40 AM, Phill B <[EMAIL PROTECTED]> wrote: > > I need some input on this. I need to keep track of changes made to > products > > in our database. The best thing I have come up with that meets the > customers > > needs is using CF to track the product using XML. The product will be > stored > > in the database but all the versions of it would be stored on the > server in > > XML with the transactions being recorded in it. > > > > Here is how I think it should work but it just doesn't feel right yet. > > > > A new product is created so an XML file is written to the server with > the > > date and user name attached. > > > > When a potential change is made, the current product will be compared > to the > > most current XML to see if anything really was changed. If a change is > > detected, a new XML file is written to the server with the date and > user > > name attached to the change. > > > > Does this sound solid enough to use or is there a better way? All input > is > > appreciated. > > > > It would be great if I could find an easy way to integrate Subversion, > CF > > and SQL2K for this but that's just crazy talk. :-) > > > > Thanks > > > > -- > > Phil > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;192386516;25150098;k Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:302860 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4