SQL Server Articles, SQL Server Tips, SQL Server Tutorials, SQL Server Tuning, SQL Server DBA, SQL Server Basics, Training, etc - MyTechMantra.com

How to Attach SSAS Database in SQL Server

This article explains How to Attach Analysis Services Database in SQL Server. The steps mentioned in this article are applicable on SQL Server 2008 and Higher Versions.

Different ways in which an Analysis Services (SSAS) Database

  • Using SQL Server Management Studio
  • Using XMLA Scripts
  • Programmatically Using Analysis Management Objects (AMO)

However, in this article we will take a look at attaching the analysis services database using SQL Server Management Studio and by Using XMLA Script.

To Detach an Analysis Services Database refer the following article “How to Detach SSAS Database in SQL Server

Attach Analysis Services Database / Attach SSAS Database Using SQL Server Management Studio

Step 1. Connect to Analysis Services Instance Using SQL Server Management Studio

Step 2. Right click Databases and then choose Attach… from the popup to open up Attach Database Dialog box.

How to Attach Analysis Services Database in SQL Server or How to Attach SSAS Database in SQL Server

Trending Analysis Services Articles and Tips

Step 3. In Attach Database Dialog box specify the location of OLAP database and specify the password incase if you give at the time of detaching the SSAS database and then click OK to attach the analysis services database. If you want to generate XMLA Script to Attach analysis Database then click on Script and then choose “Script Action to New Query Window” as shown in the below snippet.

Attach SSAS Database Using SSMS

XMLA Script to Attach Analysis Services Database in SQL Server 2008 and Higher Versions

<Attach xmlns="http://schemas.microsoft.com/analysisservices/2003/engine">
 <Folder> D:\Program Files\Microsoft SQL Server\MSAS10_50.MyTechMantra\OLAP\Data\MyTechMantra.0.db\</Folder>  <ReadWriteMode xmlns="http://schemas.microsoft.com/analysisservices/2008/engine/100">ReadWrite</ReadWriteMode>


In this article you have seen different methods in which one can attach an Analysis Services (SSAS) database in SQL Server 2008 and higher versions.

Chetna Bhalla


Chetna Bhalla, the founder of MyTechMantra.com, believes that by sharing knowledge and building communities, we can make this world a better place to live in. Chetna is a Graduate in Social Sciences and a Masters in Human Resources and International Business. She is an alumnus of Vignana Jyothi Institute of Management, Hyderabad, India. After graduation, Chetna founded this website, which has since then become quite a favorite in the tech world. Her vision is to make this website the favorite place for seeking information on Databases and other Information Technology areas. She believes that companies which can organize and deploy their data to frame strategies are going to have a competitive edge over others. Her interest areas include Microsoft SQL Server and overall Database Management. Apart from her work, Chetna enjoys spending time with her friends, painting, gardening, playing the violin, and spending time with her son.

Add comment

Newsletter Signup! Join 15,000+ Professionals

Be Social! Like & Follow Us

Follow us

Don't be shy, get in touch. We love meeting interesting people and making new friends.