Hello,

I am currently looking at moving some of my FoxPro tables to a MySQL
implementation and I am hoping someone can help me with how to do the
following.

In my current code, whenever anyone makes a change to a row the original
value of the row is written to a history table with the same name with an
"x" appended to it. In addition the "x" table has a column to name the
person who made the change and a timestamp of when it was made. I do this so
I can go back if an account appears to have paid out too much so I can see
what the value of the particular row was when a transaction was processed.

Since I am using Visual Basic and DAO/ADO right now this basically required
me to create a replacement to the .Update method that first writes the data
to the "x" table and then updates the live table.

The drawback is that I can't use a sql "Update" call because I don't have
any control over the results.

When I saw that MySQL was going to support triggers I thought this would
solve my problem since I could put in a before update and a before delete
trigger and save the old data to another table. However, after reading more
closely I see that you can't do any table access from within the stored
procedure so that will not work.

Is there any way to solve something like this in MySQL? It just seems like
something that has to have been encountered by other people.

Thanks,
Darrell


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to