CLOUD SQL 

Determining space used for all tables in a SQL Server database

Well, I tried my best and this is what I came up with:   USE SECREADER BEGIN tryDECLARE @table_name VARCHAR(500) ;DECLARE @schema_name VARCHAR(500) ;DECLARE  @temp_table TABLE (            tablename sysname,       row_count INT,       reserved VARCHAR(50) collate database_default,       data VARCHAR(50) collate database_default,       index_size VARCHAR(50) collate database_default,       unused VARCHAR(50) collate database_default,        row_id INT IDENTITY(1,1)); DECLARE c1 CURSOR FORSELECT t2.name + ‘.’ + t1.name  FROM sys.tables t1INNER JOIN sys.schemas t2 ON ( t1.schema_id = t2.schema_id );   OPEN c1;FETCH NEXT FROM c1 INTO @table_name;WHILE @@FETCH_STATUS = 0BEGIN          SET @table_name = REPLACE(@table_name,…

Read More
CLOUD SQL 

Optimizing Type 2 Slowly Changing Dimensions in Integration Services – Part 2

By: Koen Verbeeck   |   Read Comments   |   Related Tips: More > Integration Services Development Problem In the first part we introduced the reasoning behind type 2 slowly changing dimensions. We also discussed different implementation options in Integration Services (SSIS). Finally, we started with an implementation in the data flow using out-of-the-box transformations only, so we can build an optimized data flow for loading a type 2 dimension. In this tip, we’ll continue the implementation. Solution…

Read More
CLOUD SQL 

How to restore a SQL Server database to another server after disabling TDE

By: Mohammed Moinudheen   |   Read Comments   |   Related Tips: More > Restore Problem We need to restore a database using a backup from a different SQL Server where TDE is enabled for that database. On disabling TDE and then performing a backup, the database backup was copied on to the new SQL Server instance and then restored. The restore failed with this error even though TDE was disabled before performing the database backup on the source server…

Read More
CLOUD SQL 

Data Modeling: Understanding First Normal Form in SQL Server

By: K. Brian Kelley   |   Read Comments   |   Related Tips: More > Database Design Problem I’m working to improve my SQL Server database development skills, specifically in the area of data modeling. I’ve seen some information on data normalization and the forms, however, I’d like to understand them better and why they are used. Solution Data normalization is where we seek to organize the data in such a way as to reduce duplication of data…

Read More
CLOUD SQL 

Reasons to Upgrade to SQL Server 2017

By: Ameena Lalani   |   Read Comments   |   Related Tips: More > Upgrades and Migrations Problem You are on the SQL Server 2012 platform and want to upgrade to SQL Server 2017 to take advantage of all the excellent new features that came out with SQL Server 2016 and a few more added in SQL Server 2017. You need to justify to upper management what benefits the upgrade will bring to your organization. You also want to make sure…

Read More
CLOUD SQL 

How to Quickly Copy Data Using SQL Server Data Tool (SSDT)

By: Simon Liew   |   Read Comments   |   Related Tips: More > Other Database Platforms Problem I have a table with many columns in Teradata. I wanted to copy data from this Teradata table quickly to SQL Server to do some data reconciliation. Manually defining a destination table in SQL Server with the column names and its equivalent data type would be very time consuming. Do the SQL Server Data Tools (SSDT) have any features to create a…

Read More
CLOUD SQL 

Increase PowerShell available commands in a SQL Server Agent Job step

By: Pablo Echeverria   |   Read Comments   |   Related Tips: More > SQL Server Agent Problem It is often required to perform advanced operations within a SQL Server Agent Job step, like interact with the operating system or import custom modules. For this, you’re able to create a PowerShell type step, but the problem is that the Powershell version varies when it runs inside a job step, so many people recommend (link link link) creating a…

Read More
CLOUD SQL 

Managing your active SQL Server instance list using PHP

By: Graham Okely   |   Read Comments   |   Related Tips: More > Database Administration Problem What SQL Server instances do you manage?  What environment is each one in? Can you add or remove instances from your master list easily?  In this tip, we will look at a simple way to manage your list of SQL Server instances using PHP and SQL Server. Solution In this tip some PHP code is discussed to help you manage a list of…

Read More
CLOUD SQL 

Locally Weighted Scatterplot Smoothing (Lowess) approach in Power BI

By: Esat Erkec   |   Read Comments   |   Related Tips: More > Power BI Problem How do apply the Locally Weighted Scatterplot Smoothing (Lowess) method and find out the trend of a data series in Power BI? Solution In some cases, linear regression cannot clarify relationships between variables and cannot detect the trend of a data series. For this reason, we can apply other regression methods in statistics. Locally Weighted Scatterplot Smoothing also known as the…

Read More
CLOUD SQL 

6 Ways to Add Value to Your LinkedIn Network

By: Cate Murray   |   Read Comments   |   Related Tips: More > Professional Development Branding Problem Are you new to LinkedIn or revamping your profile to be more attractive, detailed, and credible to potential employers?  On the other hand, are you simply trying to be more active so you stay better connected with your network? If so, it is important to understand how easy it is to add value to your LinkedIn network, and why you should take…

Read More