J
José António Silva
Hello,
The following applies to VBA with ADO and SQL Server 2000
I want to use a trigger to manage the deletion of records in a table.
However, I have a procedure in VBA that creates a new connection with the
server, which can be run by any user, and where I don’t want the trigger to
fire.
I investigated the use of SET CONTEXT_INFO but I cannot understand if I can
set the respective value from VBA. In this case I will insert a condition in
the trigger to test the existence of a certain value.
I also investigated the creation of a temporary table in VBA but I am
convicted that trigger cannot find this table because of an out of scope
problem. In this case I will insert a condition in the trigger to test for
the existence of that table.
I hope somebody has an elegant solution for this,
Thank you,
José António Silva
The following applies to VBA with ADO and SQL Server 2000
I want to use a trigger to manage the deletion of records in a table.
However, I have a procedure in VBA that creates a new connection with the
server, which can be run by any user, and where I don’t want the trigger to
fire.
I investigated the use of SET CONTEXT_INFO but I cannot understand if I can
set the respective value from VBA. In this case I will insert a condition in
the trigger to test the existence of a certain value.
I also investigated the creation of a temporary table in VBA but I am
convicted that trigger cannot find this table because of an out of scope
problem. In this case I will insert a condition in the trigger to test for
the existence of that table.
I hope somebody has an elegant solution for this,
Thank you,
José António Silva