?
SolvedPrivate

Translate SQL Query to MDX

Posted on 2015-01-15
1
Medium Priority
?
36 Views
Last Modified: 2016-02-18
Is there any way to translate the below query, to MDX format ? i'm having trouble with grouping.....

select Site, [Date Time],
COUNT([Agent Name]) cntAgents,
SUM([Available Time Net]) Sum(AvailTime),
Sum([Logged On Time Net]) SumLoggedOnTime,
SUM([Not Ready Time Net]) SumNotReadyTime,
SUM([Calls Answered]) SumCallsAnswered, SUM([Handled Calls Talk Time])
Sum(HandledCallsTalkTime)
from dbo.temp_AgentTimenet (this would be the cube [Agent Time Net]
where Site = 'WBD'
and  [Date Time] between '2014-08-01 00:00' and '2014-12-31 23:59'
group by [Site], [Date Time]
order by [Date Time]
0
Comment
Question by:Auerelio Vasquez
[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
1 Comment
 
LVL 24

Accepted Solution

by:
Phillip Burton earned 2000 total points
ID: 40553025
It largely depends on how your cube is set up.

Try going to the Cube - Browser within SSMS and using the GUI to create the query, and then click on "Design Mode" to see the resulting MDX.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

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

Recently we ran in to an issue while running some SQL jobs where we were trying to process the cubes.  We got an error saying failure stating 'NT SERVICE\SQLSERVERAGENT does not have access to Analysis Services. So this is a way to automate that wit…
It is possible to export the data of a SQL Table in SSMS and generate INSERT statements. It's neatly tucked away in the generate scripts option of a database.
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses

765 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