Question : Try to create a database in SQL Server Analysis Server (SQLAS, SSAS) version 2012 SP2 if that matters […]
Tag: powershell
Invoke-SQLCMD with special characters
Question : I’m currently working on a project integrating AD with SQL Server data, which I am handling mainly via […]
How to catch error from sql server on powershell?
Question : I have written powershell script that executes all sql from folder, but I want to stop executing on […]
SQL Server 2019 setting Force Encryption with a script
Question : I have to update 50+ servers to use encrypted connection strings. Is there a way to script setting […]
To generate a script to drop or map the orphan users in a SQL Server Instance
Question : I am very new to SQL Server. I have a script which find the orphan users in all […]
Query Multiple SQL Server Instances using Powershell referencing the list of instances in a text file
Question : Rather than issuing a query per instance via SQL Server Management Studio, we are trying to create a […]
SQL Visual Studio Find and Replace in Publish Profile
Question : We have source control in Visual Studio Database Projects (SSDT). To make cross database references, we utilize something […]
How to get table columns with datatypes (and lengths) using PowerShell?
Question : I’m trying to get column names with data types (and lengths) for SQL Server instance using PowerShell. I […]
Automation of MSSQL database transaction log file truncation
Question : I am looking into setting up an automated process through PowerShell or anything for truncating SQL Server transaction […]
Powershell SQL Script Execution in Selected Schemas Only
Question : I have many schemas in one database. In that database I have some SQL scripts to be executed. […]