Using PowerPivot’s Copy-Paste Support for Importing Data from Word

Using PowerPivot’s Copy-Paste Support for Importing Data from Word

Share on Facebook0Share on Google+0Tweet about this on TwitterShare on LinkedIn0Share on Reddit0
One of the great features of SQL Server PowerPivot is that it supports importing data directly from the clipboard. This is quite handy in cases you want to import and analyze data fast.

An example of using the above feature is importing data from Microsoft Word. Let’s say you have a Word document containing the following table:

The scenario here is to import the data from Word and perform a simple analysis.

The first step is to select the entire table and copy its contents to the clipboard.

Then you have to launch Excel 2010 and open the PowerPivot window:


 
 
 
 
 

Click on “To New Table” and you will be presented with a Paste Preview dialog in which you will be able to see the contents of the clipboard and how they are “translated” by the PowerPivot engine:

At the bottom of the dialog you can choose to use the first row as column names and that’s what I did in this example.

You then click on “OK” and you are presented with the data as imported into PowerPivot:

 
 
 
 
 
 
 
 
 

Next, by clicking on the “PivotTable” button you are presented with various options regarding what type(s) of pivot tables you can create:
 

For this example I chose to use a “Single PivotChart”.
Then, the PowerPivot dialog closes and the Excel worksheet is presented containing the pivot table:

You can then easily perform aggregations using the tools provided by PowerPivot:

 

Well, I guess that’s it for today! I hope you found this post useful!

Another post on copy-paste and PowerPivot is coming where we will see how we can copy-paste two tables from Word and build relationships on the data.


Recommended eBooks on SQL Server:

Tuning SQL Server: eBook by SQL Server MVP Artemakis Artemiou
Tuning SQL Server: eBook by SQL Server MVP Artemakis Artemiou
Administering SQL Server: eBook by SQL Server MVP Artemakis Artemiou
Administering SQL Server: eBook by SQL Server MVP Artemakis Artemiou
Artemakis Artemiou
Artemakis Artemiou is a Senior SQL Server Architect, Author, Software Developer and a Microsoft Data Platform MVP. He has over 15 years of experience in the IT industry in various roles. Among other, via his initiative SQLEBooks.com, Artemakis authors and publishes eBooks on different topics on SQL Server. Artemakis currently serves as the President of the Cyprus .NET User Group (CDNUG) and the International .NET Association Country Leader for Cyprus (INETA). Additionally he is the founder of the SQLArtBits initiative that aims to provide the technical community with simple, yet powerful and high-quality SQL Server tools. Currently, the highlights of these tools are DBA Security Advisor and In-Memory OLTP Simulator. Artemakis's official website can be found at aartemiou.com. Artemakis's blogs can be found at: SQLNetHub.com and TechHowTos.com.