Three times a day I need to drop a table (say, TABLE1) and rename another freshly imported, prepped and indexed table (say, TABLE1_TEMP). They are the exact same table, one just has more current MTD info. I keep getting locked out from dropping TABLE1 as people are running selects and views off of it.
It may sound strange how I am dropping and re-naming tables, but it's the only way this particular set of tables will work. Plus it only takes a millisecond so users would only notice if they ran a view right at that millisecond.
I want to completely unlock TABLE1 so I can drop it when necessary. Is there a way I can build that into the table structure? Or am I stuck with the SQL Server lock contentions.
Keep in mind I do not need to insert update and delete rows (that's actually the beuty of it) so all users can be read only. I don't mind if they get cut off in the middle of a query either.
It may sound strange how I am dropping and re-naming tables, but it's the only way this particular set of tables will work. Plus it only takes a millisecond so users would only notice if they ran a view right at that millisecond.
I want to completely unlock TABLE1 so I can drop it when necessary. Is there a way I can build that into the table structure? Or am I stuck with the SQL Server lock contentions.
Keep in mind I do not need to insert update and delete rows (that's actually the beuty of it) so all users can be read only. I don't mind if they get cut off in the middle of a query either.