Few days ago I received a request to restore a dozen of tables because someone have deleted more data than it was supposed. I immediately thought about dbatools for the job! NOTE: I also thought about SSMS “Import/Export Data”. And this is ok when someone says “it’s to run just once, just now”. When you are in the IT for a while you know that is not only once :-). And what if I need to re-run?

Continue reading

Probably you had the need to script out some objects from a SQL Server instance/database and this is quite easy. You just need to right click on the object (well…not on every single one, try it with an Availability Group :-), no script option available) select “Script XXXX as” and you have it. But have you realized that this option doesn’t bring all the stuff? Let’s say you are scripting a table and you have a Non-Clustered index or a trigger…using this option some of the objects under the table will not be scripted out.

Continue reading

Few days ago a client requested the configuration of MSDTC (Microsoft Distributed Transaction Coordinator). NOTE: If you want to know more about it here is a nice FAQ from Microsoft blogs - MSDTC Recommendations on SQL Failover Cluster ? The client has 2 machines: one an application server and one a database server. Both run on Windows Server 2016 OS and, the database server runs SQL Server 2016 using Availability Groups feature (where their databases resides).

Continue reading

One of the good things, when we have new clients, is that sometimes they have needs that you never heard before. This does not necessarily mean that they are complex. As a matter of fact, they can be really simple..now the question is..are they doable? :-) From my experience, this can happen mainly because one of two reasons, they have some very specific need, or because the way the application is built will make you work with features that you haven’t played yet.

Continue reading

This post is to answer the question: “You are used to seeing in the format of yyyy-MM-dd right?” that I have raised on my blog post Don’t cutoff yourself with dates in T-SQL – Did you know… . As you could see from that blog post, my screen shots were from VSCode and in this case using mssql extension, but this happens also on SQL Server Operations Studio . “But why are my datetimeoffset values on VSCode being showed in that format?

Continue reading

Author's picture

Cláudio Silva

Data Platform Architect and PowerShell lover.

Data Platform Architect

Portugal