New answers tagged

0

I found this article while searching for this type of script and worked from a few resources to create these from a SQL 2019 server. -- List partitioned tables (excluding system tables) SELECT DISTINCT so.name FROM sys.partitions sp JOIN sys.objects so ON so.object_id = sp.object_id where name NOT LIKE 'sys%' and name NOT LIKE 'sqla%' and name ...


0

There is one more way by creating a dacpac and then importing it in SQL server. You can then build the solution and it will show you all the errors that It will encounter with the whole database. Please note that you need to create DACPAC for all the linked databases. Hope it help.


0

DECLARE @hid_Specific HIERARCHYID /** Assign your specific node path **/ SET @hid_Specific='/1/1/3/1/'; SELECT hrchy_id, * FROM tblHierarchyData WHERE PATINDEX(hrchy_id.ToString()+'%',@hid_Specific.ToString())=1


0

Paul White has a really detailed post about a way to get minimal logging for INSERT...SELECT statements that target clustered tables with secondary indexes. Check out the full article here: Minimal Logging with INSERT…SELECT and Fast Load Context The main thing you're probably missing is that you need to enable trace flag 610. Read the whole thing to see ...


Top 50 recent answers are included