Book Image

SQL Server 2014 with PowerShell v5 Cookbook

By : Donabel Santos
Book Image

SQL Server 2014 with PowerShell v5 Cookbook

By: Donabel Santos

Overview of this book

Table of Contents (21 chapters)
SQL Server 2014 with PowerShell v5 Cookbook
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Chapter 2. SQL Server and PowerShell Basic Tasks

In this chapter, we will cover:

  • Listing SQL Server instances

  • Discovering SQL Server services

  • Starting/stopping SQL Server services

  • Listing SQL Server configuration settings

  • Changing SQL Server Instance configurations

  • Searching for database objects

  • Scripting SQL Server Stored Procedures

  • Creating a database

  • Altering database properties

  • Dropping a database

  • Changing a database owner

  • Creating a table

  • Creating a view

  • Creating a stored procedure

  • Creating a user defined function

  • Creating a trigger

  • Creating an index

  • Executing a query / SQL script

  • Performing bulk export using Invoke-SqlCmd

  • Performing bulk export using the bcp command-line utility

  • Performing bulk import using BULK INSERT

  • Performing bulk import using the bcp command-line utility

  • Connecting to an Azure SQL database

  • Creating a table in an Azure SQL database