Solved

SQL Query Analyzer to Excel

Posted on 2013-05-13
8
285 Views
Last Modified: 2013-05-13
Good Day Experts!

Hope you all can help me with my dilemna.  I have query results in QueryAnalyzer.  I need to get it to Excel.  I cannot save as CSV as some of the column values have commas in them.  

What is the best way to get this data into Excel?

Thanks,
jimbo99999
0
Comment
Question by:Jimbo99999
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
8 Comments
 
LVL 18

Accepted Solution

by:
x-men earned 500 total points
ID: 39161866
create a data source in Excel, pointing to your server and run the query directly.

Menu: Data - From Other Sources - From SQL Server
fill out the wizard

You'll get the table in Excel.

Select a cell (from the table) go to Data - Connections - Properties - Definition:
Command Type: SQL
Command Text: Your query
0
 

Author Comment

by:Jimbo99999
ID: 39161902
Thanks for responding.  But I am not sure where to put the query that I was using in QueryAnalyzer?
0
 
LVL 18

Expert Comment

by:x-men
ID: 39161920
Select a cell (from the new created table) go to Data - Connections - Properties - Definition:
Command Type: SQL
Command Text: Your query
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:Jimbo99999
ID: 39161951
I cannot afford to import the entire contents of the SQL table into Excel and then query it.
0
 
LVL 18

Expert Comment

by:x-men
ID: 39161987
after you click the Finish button of the wizard, a new window will appear, where you chose the range to place the data. Click the properties button on that window, click the Definition tab, change the "Command Type" to SQL, and place your query on the "Command text" area
0
 

Author Comment

by:Jimbo99999
ID: 39162002
Ok, I will try now.  I was not aware of this in Excel and appreciate your patience with my first time use.

Thanks,
jimbo99999
0
 

Author Comment

by:Jimbo99999
ID: 39162089
It is working great.  Thanks for the help. I know have another tool in my back pocket.

Thanks,
jimbo99999
0
 
LVL 18

Expert Comment

by:x-men
ID: 39162116
try the PowerPivot feature. You're gonna love it ;)
0

Featured Post

Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

The Delta outage: 650 cancelled flights, more than 1200 delayed flights, thousands of frustrated customers, tens of millions of dollars in damages – plus untold reputational damage to one of the world’s most trusted airlines. All due to a catastroph…
Freeze panes is an option within all variants of Excel to enable parts of a sheet to remain stationary when the cursor is in another part of the sheet. This is a very useful feature which is overlooked or under used.
Graphs within dashboards are meant to be dynamic, representing data from a period of time that will change each time the dashboard is updated with new data. Rather than update each graph to point to a different set within a static set of data, t…
This Micro Tutorial will demonstrate in Microsoft Excel how to add style and sexy appeal to horizontal bar charts.

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question