SQL
Automate migration to SQL Managed Instance using Azure PowerShell and DbaTool
(techcommunity.microsoft.com)
From: JovanPop MicrosoftIn Microsoft Azure, you can easily migrate your databases from SQL Server
By: submitted:Jun 15 2022
From: JovanPop MicrosoftIn Microsoft Azure, you can easily migrate your databases from SQL Server
on-premises or Azure VMs to the fully-managed PaaS database service Azure SQL Database Managed Instance. In this post you will see how to create PowerShell scripts that automate migration to Managed Instance using Azure PowerShell and DbaTools.
By: submitted:Jun 15 2022
Automate Your Daily Database Checks with PowerShell
(youtube.com)
You'll get a glimpse of how I do health checks for large SQL Server Always On Availability Groups at
By: Edwin M Sarmiento submitted:Oct 18 2024
You'll get a glimpse of how I do health checks for large SQL Server Always On Availability Groups at
the end of the video.
By: Edwin M Sarmiento submitted:Oct 18 2024
ConvertTo-SQLSelect
(nocolumnname.blog)
There are times when I want to mess about with data in SQL Server, data that I have obtained in
By: Shane O'Neill submitted:Jun 16 2022
There are times when I want to mess about with data in SQL Server, data that I have obtained in
PowerShell. This will require some way to get the information from PowerShell into SQL Server.
By: Shane O'Neill submitted:Jun 16 2022
Create the Optimize Database Solution using PowerShell and dbatools
(stevethompsonmvp.wordpress.com)
Let's automate the creation of this optimization solution using PowerShell and DBATools. Let's get
By: Steve Thompson submitted:Jun 16 2022
Let's automate the creation of this optimization solution using PowerShell and DBATools. Let's get
building!
By: Steve Thompson submitted:Jun 16 2022
Getting Started with PowerShell Invoke-SQLCmd Command
(adamtheautomator.com)
The PowerShell Invoke-SQLCmd cmdlet offers a powerful way of interacting with SQL databases. Learn
By: Victor Silva submitted:Apr 7 2023
The PowerShell Invoke-SQLCmd cmdlet offers a powerful way of interacting with SQL databases. Learn
how to use this command in this ATA Learning tutorial!
By: Victor Silva submitted:Apr 7 2023
How to import/export data between SQL Server and Excel using PowerShell?
(bronowski.it)
ImportExcel is a powerful tool to manage MS Excel, however, the user is not limited to data stored
By: Mikey Bronowski submitted:Jun 16 2022
ImportExcel is a powerful tool to manage MS Excel, however, the user is not limited to data stored
in worksheets. We can import from and export to SQL Excel data using a combination of ImportExcel and dbatools modules.
By: Mikey Bronowski submitted:Jun 16 2022
How to Run SQL Assessment Checks in Azure SQL MI (YouTube)
(youtube.com)
In this episode with Aaron Nelson, we'll show you the basics of the SQL Assessment PowerShell
By: Aaron Nelson and Anna Hoffman submitted:Jun 16 2022
In this episode with Aaron Nelson, we'll show you the basics of the SQL Assessment PowerShell
commands, and how you can run the assessments for your Azure SQL Managed Instances as well as your on-prem SQL Server instances.
By: Aaron Nelson and Anna Hoffman submitted:Jun 16 2022
Invoke-ParameterisedSqlQuery.ps1
(gist.github.com)
Invoke-SqlCmd doesn't support parameterised queries, so you have to resort to magic strings, and
By: Neil Barnwell submitted:Jun 16 2022
Invoke-SqlCmd doesn't support parameterised queries, so you have to resort to magic strings, and
possibly leave yourself open to SQL injection attacks. While you may be the only one using your script, it's likely that you're using values you're getting from a database, file, or some other external source. So I finally got around to writing a function that supports parameterised queries, and thought I'd offer it up in case others find it useful.
By: Neil Barnwell submitted:Jun 16 2022
Learn dbatools in a Month of Lunches
(manning.com)
An effective DBA is an efficient DBA. And if you work with SQL Server, dbatools is a lifesaver. With
By: submitted:Jun 15 2022
An effective DBA is an efficient DBA. And if you work with SQL Server, dbatools is a lifesaver. With
over 500 commands, this free and open source PowerShell module has the horsepower to automate just about every task you can imagine?and then some! Written by dbatools creator Chrissy LeMaire and dbatools advocate Rob Sewell, Learn dbatools in a Month of Lunches teaches you techniques that will make you more effective?and efficient?than you ever thought possible.
By: submitted:Jun 15 2022
Lesson Learned From Multi-Threading with dbatools
(flxsql.com)
Over the summer, I spent some (a lot of) time working on updates to a script at work which runs
By: Andy Levy submitted:Jun 16 2022
Over the summer, I spent some (a lot of) time working on updates to a script at work which runs
multiple processes in parallel. Everything seemed to work OK for a while, but then everything broke.
By: Andy Levy submitted:Jun 16 2022
Moving SQL Server System Databases With PowerShell
(onsb.co)
One task that I was frequently finding myself spending more time than necessary with was building
By: Dane submitted:Jun 16 2022
One task that I was frequently finding myself spending more time than necessary with was building
out SQL Servers. The chief time consuming task being when I'd have to move the SQL Server's default System Database and Log Files to new, dedicated database and log volumes.
By: Dane submitted:Jun 16 2022
PIVOT in PowerShell
(nocolumnname.blog)
Exploring our Data SQL Pivoting PowerShell Grouping our Data Manual Pivot Dynamic Pivot
By: Shane O'Neill submitted:Jun 16 2022
Exploring our Data SQL Pivoting PowerShell Grouping our Data Manual Pivot Dynamic Pivot
By: Shane O'Neill submitted:Jun 16 2022
PowerShell for DBAs
(github.com)
I don't want to build a product or module. I want to provide a proof of concept, a tutorial, a code
By: Andreas Jordan submitted:Sep 9 2022
I don't want to build a product or module. I want to provide a proof of concept, a tutorial, a code
example, maybe a guide or a source of ideas for your own implementation. This is about using publicly available software (like database clients or NuGet packages) and a few lines of PowerShell code to show database administrators how to work with PowerShell.
By: Andreas Jordan submitted:Sep 9 2022
PowerShell Notebooks are Available in Azure Data Studio
(sqlvariant.com)
PowerShell Notebooks are now available in the November release of Azure Data Studio. Back in March I
By: Aaron Nelson submitted:Jun 15 2022
PowerShell Notebooks are now available in the November release of Azure Data Studio. Back in March I
requested this feature be added to Azure Data Studio and it has become the most popular feature request for Notebooks. (Although, I'm sure it only became the most popular after they added copying from the results grid a few months ago )
By: Aaron Nelson submitted:Jun 15 2022
Prometheus data from PowerShell
(oxcrag.net)
At work we have a system which is dependent on fetching email from an on-premises Exchange server
By: Mikael Hansson submitted:Jan 12 2024
At work we have a system which is dependent on fetching email from an on-premises Exchange server
via Exchange Web Services (EWS). Apparently there's a "wontfix" bug in Exchange, where a request to fetch email over this interface that can silently fail. The known workaround is to move email between folders in the affected account, which for some reason causes a state change of some kind that suddenly allows email to be handled again.
By: Mikael Hansson submitted:Jan 12 2024
Running Multiple Instances of SqlBulkCopy in Parallel from PowerShell
(techcommunity.microsoft.com)
Today, we encountered an interesting service request of attempting to reduce the load times for
By: Jose Manuel Jurado Diaz submitted:Jun 23 2023
Today, we encountered an interesting service request of attempting to reduce the load times for
100,000 records from a table with 97 varchar(320) fields in an Azure SQL HyperScale database. Following, I would like to share my lessons learned here.
By: Jose Manuel Jurado Diaz submitted:Jun 23 2023
Scripting SQL Server objects with PsDbaTools ??? Beyond default options
(claudioessilva.eu)
Let Cl?udio show you some good tips and tricks to get the most out of PsDbaTools.
By: submitted:Jun 15 2022
Let Cl?udio show you some good tips and tricks to get the most out of PsDbaTools.
By: submitted:Jun 15 2022
Search SQL Server Errorlog with PowerShell
(sqladm.in)
The SQL Server errorlog has a misleading name. There is a lot more information in it than just
By: Jeff Hill submitted:Jun 16 2022
The SQL Server errorlog has a misleading name. There is a lot more information in it than just
errors. The version, startup parameters, memory settings and a ton more. I've been working with SQL Server for over 20 years and I still see messages in the errorlog that I don't remember coming across.
By: Jeff Hill submitted:Jun 16 2022
SQL Query Stats via Powershell
(flxsql.com)
Checking query runtimes via PowerShell
By: Andy Levy submitted:Sep 27 2024
Checking query runtimes via PowerShell
By: Andy Levy submitted:Sep 27 2024
Stop or Start SQL Server With PowerShell
(sqladm.in)
Starting or stopping SQL Server isn't an everyday occurrence but when you need to, you have several
By: Jeff Hill submitted:Jun 16 2022
Starting or stopping SQL Server isn't an everyday occurrence but when you need to, you have several
options
By: Jeff Hill submitted:Jun 16 2022
Use PowerShell to Automate Backing up and Restoring an SQL Database
(youtube.com)
In this video, we demonstrating writing a PowerShell script that backs up an SQL database and
By: AIP IT Solutions submitted:Sep 29 2023
In this video, we demonstrating writing a PowerShell script that backs up an SQL database and
restores the database from a .bak file to a differently named database.
By: AIP IT Solutions submitted:Sep 29 2023
Using a LiteDB portable database with your PowerShell project
(smsagent.blog)
I was working on a PowerShell project recently where I needed to reference a large number of items -
By: Trevor Jones submitted:Jun 16 2022
I was working on a PowerShell project recently where I needed to reference a large number of items -
more than I wanted to add as an array or hash table in script, or even an external file like an XML document. So I searched for a portable, standalone database that I could distribute with the script and happened across LiteDB, a lightweight, single-file NoSQL database. It seemed the ideal solution as there's a .Net code library for it, and so far I'm pretty impressed.
By: Trevor Jones submitted:Jun 16 2022
Using Azure Automation and Runbooks to Run Azure SQL Database Maintenance Tasks | Tracy Boggiano’s Blog
(tracyboggiano.com)
I've been using Azure SQL Database for quite some while and have set up it in many various ways to
By: Tracy Boggiano submitted:Jun 9 2023
I've been using Azure SQL Database for quite some while and have set up it in many various ways to
run Ola's Index Optimize and Statistics Updates on them. All of these have seemed way too complicated probably because I was setting them up once, not again for several more months or a year. Well
By: Tracy Boggiano submitted:Jun 9 2023