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

Listing SSAS cmdlets


This recipe lists the available SSAS cmdlets in SQL Server 2014.

How to do it...

Let's explore the code required to list the SSAS cmdlets:

  1. Open PowerShell ISE as an administrator.

  2. Add the following script and run it:

    Get-Command -Module SQLASCmdlets

    This will give a result similar to this:

How it works...

A handful of SSAS cmdlets were introduced in SQL Server 2012 and carried over to SQL Server 2014. You can import the SQLASCMDLETS module to start using the new cmdlets.

To list the new AS cmdlets, simply use Get-Command:

Get-Command -Module SQLASCmdlets

You will notice that some of the common SSAS tasks have been wrapped in cmdlets, such as Backup-ASDatabase, Restore-ASDatabase, Invoke-ASCmd, Invoke-ProcessCube, and so on.

There's more...

Check out these MSDN articles: