Real-World PowerShell for SQL Admininistration
[Pages:53]Real-World PowerShell for SQL Administration
Brian Hansen brian@ @tf3604
Welcome to SQL Saturday
? Enjoy this day of learning ? Be sure to visit and thank the sponsors ? Be sure to thank the organizer and volunteers ? Take time to NETWORK with others. That's
what this is really all about! ? Act professionally and treat others with
respect (like this was a work environment)
Agenda
? "Gotchas" ? Tips ? PowerShell and .NET ? Scripts
? Gotchas
? Tips ? PowerShell and .NET ? Scripts
"Gotchas": Providers
? Be in the right provider
? PowerShell has many virtual drives and folder structures
? What is the default provider in SQL Agent?
It is SQLSERVER:\ Set-Location c:;
"Gotchas": Silent Failures
? Silent failures (non-terminating errors)
"Gotchas": Silent Failures
? How to fix? $ErrorActionPreference = "Stop";
? But what if we really want to ignore an error?
try { ... } catch { ... } finally { ... }
"Gotchas": Silent Failures
? More about try ... catch ... finally
try { $connection.Open(); } catch [System.Data.SqlClient.SqlException] {
$except = $_.Exception; $errorMessage = $except.Message; $errorNumber = $except.Number; }
................
................
In order to avoid copyright disputes, this page is only a partial summary.
To fulfill the demand for quickly locating and searching documents.
It is intelligent file search solution for home and business.
Related download
- the microsoft excel file format openoffice
- 1 2 https 1zlows
- c import data from excel to sql server
- scripts to re run configuration how to force intune
- five ways to create macro variables a short introduction
- data wrangling tidy data pandas python data analysis
- xml and json recipes for sql server a problem solution
- real world powershell for sql admininistration
- github export issues to spreadsheet
- programming visual
Related searches
- real world problems for kids
- real world problems for students
- real world topics for students
- powershell import sql module
- real world math for kids
- powershell invoke sql command
- powershell query sql table
- powershell execute sql command
- powershell list sql server instances
- powershell execute sql file
- powershell run sql script
- powershell query sql server