문제

I've created server scope ddl trigger to audit user activities on the server.
Now if someone tries to create in-memory table the statement fails with the following error:

Error SQL72014: .Net SqlClient Data Provider: Msg 12332, Level 16, State 107,
Line 1 Database and server triggers on DDL statements DROP and CREATE are not
supported with memory optimized tables.

Can I create ddl trigger that will ignore actions on in-memory tables?

도움이 되었습니까?

해결책

No, databases with In-Memory OLTP enabled do not support DDL triggers.

Both database-level and server-level DDL triggers are not supported with In-Memory OLTP tables and natively compiled modules.

You cannot create DDL triggers in a database where In-Memory OLTP is enabled since the code path required to run the trigger would interfere with the In-Memory functionality. The workaround is to put all your In-Memory OLTP tables in a single database without a DDL trigger, and the rest of your tables into a separate database without memory-optimized tables, and enable the DDL Trigger there.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 dba.stackexchange
scroll top