Hi all,
Here is my issue:
In sql-2005, I have an audit table, to which I write when certain changes to certain fields are made. This happens in a trigger. The key piece of info for the audit table is the hostname which I get from Sysprocesses. The problem is that it is NOT the actual computername of the computer doing the change. It appears to be 'cached', which to me is useless for this purpose.
In the front-end I'm completely deleting and closing connections in this app and re-initiating them but that does not seem to work.
The front-end is an Access 2003 application. When the user opens the app, all linked-tables are *deleted* (the access odbc-link is deleted) and a brand new access odbc link is made. There is also an adodb connection that this app uses. The connection is closed, set to nothting, and reopened.
So I was working on this app at home, and sysprocesses had my home machine as hostname, which was correct last night. I copied from home to my work machine, (my home machine is not even on our domain, but i'm vpn'd in) and restarted the app--which does all the closing, re-linking,etc. So this morning on my office machine, my home machine shows up in the audit table when I change fields to the table with the trigger. This is really troubling.
So my question is what do I have to do (prefferably within the Access app--I have an 'initialize' function) to make sure that the spid for either the ado connection or linked tables is giving me accurate information for these audit tables?
Thanks,
--Jim
Here is my issue:
In sql-2005, I have an audit table, to which I write when certain changes to certain fields are made. This happens in a trigger. The key piece of info for the audit table is the hostname which I get from Sysprocesses. The problem is that it is NOT the actual computername of the computer doing the change. It appears to be 'cached', which to me is useless for this purpose.
In the front-end I'm completely deleting and closing connections in this app and re-initiating them but that does not seem to work.
The front-end is an Access 2003 application. When the user opens the app, all linked-tables are *deleted* (the access odbc-link is deleted) and a brand new access odbc link is made. There is also an adodb connection that this app uses. The connection is closed, set to nothting, and reopened.
So I was working on this app at home, and sysprocesses had my home machine as hostname, which was correct last night. I copied from home to my work machine, (my home machine is not even on our domain, but i'm vpn'd in) and restarted the app--which does all the closing, re-linking,etc. So this morning on my office machine, my home machine shows up in the audit table when I change fields to the table with the trigger. This is really troubling.
So my question is what do I have to do (prefferably within the Access app--I have an 'initialize' function) to make sure that the spid for either the ado connection or linked tables is giving me accurate information for these audit tables?
Thanks,
--Jim