This article is nice ( we have a little bug ) , and the SQL script is not execute-safe (if you run twice, you have errors ). It is for a specific database, when you need to save all SQL Server, you must run for each database. 1 2PRINT '-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --' 3PRINT '-- SQL Security...
Transform table definition to XML select, it can be useful when we need to create many XML select or re-create it. Result: 1 2SELECT 3 [Message].value('(msg_Customers/Customers/CustomerID)[1]', 'nchar(5)') as [CustomerID] 4, [Message].value('(msg_Customers/Customers/CompanyName)[1]', 'nvarchar(40)') as [CompanyName] 5,...