If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Audit log for 1 field
Hi. I am trying to create an audit log for a "tasks" database.I used Allen
Browne's code and got it working on a very simple test database. When I try to do the exact thing in my production database, it gets stuck at: 'Remove any cancelled update still in the tmp table. Set db = DBEngine(0)(0) sSQL = "DELETE FROM " & sAudTmpTable & ";" db.Execute sSQL My production form has alot on it (combo lookups, date pickers, option groups, and some code behind some text boxes, etc). Would this affect it? I'm really only interested in tracking changes from 1 field. How can I modify Allen's code to do this and stop erroring out? Thanks! |
#2
|
|||
|
|||
Audit log for 1 field
What does "gets stuck" mean? Do you get an error? If so, what's the error?
-- Doug Steele, Microsoft Access MVP http://I.Am/DougSteele (no private e-mails, please) "BenEl" u56454@uwe wrote in message news:9f9c5f2324d32@uwe... Hi. I am trying to create an audit log for a "tasks" database.I used Allen Browne's code and got it working on a very simple test database. When I try to do the exact thing in my production database, it gets stuck at: 'Remove any cancelled update still in the tmp table. Set db = DBEngine(0)(0) sSQL = "DELETE FROM " & sAudTmpTable & ";" db.Execute sSQL My production form has alot on it (combo lookups, date pickers, option groups, and some code behind some text boxes, etc). Would this affect it? I'm really only interested in tracking changes from 1 field. How can I modify Allen's code to do this and stop erroring out? Thanks! |
#3
|
|||
|
|||
Audit log for 1 field
"Syntex error in FROM clause".
I don't understand this error, because the code is copied straight from Allen's website and worked perfectly in my test dbase. Douglas J. Steele wrote: What does "gets stuck" mean? Do you get an error? If so, what's the error? Hi. I am trying to create an audit log for a "tasks" database.I used Allen Browne's code and got it working on a very simple test database. When I [quoted text clipped - 14 lines] Thanks! -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...forms/200911/1 |
#4
|
|||
|
|||
Audit log for 1 field
If sAudTmpTable contains special characters (which includes spaces), try
sSQL = "DELETE FROM [" & sAudTmpTable & "];" If it doesn't, what's the actual content of sSQL when the code fails? -- Doug Steele, Microsoft Access MVP http://I.Am/DougSteele (no e-mails, please!) "BenEl via AccessMonster.com" u56454@uwe wrote in message news:9fa530926c82e@uwe... "Syntex error in FROM clause". I don't understand this error, because the code is copied straight from Allen's website and worked perfectly in my test dbase. Douglas J. Steele wrote: What does "gets stuck" mean? Do you get an error? If so, what's the error? Hi. I am trying to create an audit log for a "tasks" database.I used Allen Browne's code and got it working on a very simple test database. When I [quoted text clipped - 14 lines] Thanks! -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...forms/200911/1 |
#5
|
|||
|
|||
Audit log for 1 field
So that worked! Now I'm getting the error:
" SELECT* can not be used in an INSERT INTO query where the source or destination table contains a multivalued field". I have a few of these. I don't want to capture the changes for these fields. How can I adopt the code to only look at one specific field? Thanks. Douglas J. Steele wrote: If sAudTmpTable contains special characters (which includes spaces), try sSQL = "DELETE FROM [" & sAudTmpTable & "];" If it doesn't, what's the actual content of sSQL when the code fails? "Syntex error in FROM clause". [quoted text clipped - 9 lines] Thanks! -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...forms/200911/1 |
#6
|
|||
|
|||
Audit log for 1 field
In AuditEditEnd, you have to change sSQL so that it picks selected fields,
not *. -- Doug Steele, Microsoft Access MVP http://I.Am/DougSteele (no e-mails, please!) "BenEl via AccessMonster.com" u56454@uwe wrote in message news:9fa78f1eb9a06@uwe... So that worked! Now I'm getting the error: " SELECT* can not be used in an INSERT INTO query where the source or destination table contains a multivalued field". I have a few of these. I don't want to capture the changes for these fields. How can I adopt the code to only look at one specific field? Thanks. Douglas J. Steele wrote: If sAudTmpTable contains special characters (which includes spaces), try sSQL = "DELETE FROM [" & sAudTmpTable & "];" If it doesn't, what's the actual content of sSQL when the code fails? "Syntex error in FROM clause". [quoted text clipped - 9 lines] Thanks! -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...forms/200911/1 |
#7
|
|||
|
|||
Audit log for 1 field
Thanks. Unfortunately the user has decided that they would now like to be
able to modify past entries...Onto a new tactic! Douglas J. Steele wrote: In AuditEditEnd, you have to change sSQL so that it picks selected fields, not *. So that worked! Now I'm getting the error: [quoted text clipped - 18 lines] Thanks! -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...forms/200911/1 |
Thread Tools | |
Display Modes | |
|
|