SolvedPrivate

Translate SQL Query to MDX

Posted on 2015-01-15
1
34 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 500 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

Independent Software Vendors: 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!

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…
In this blog post, we’ll look at how ClickHouse performs in a general analytical workload using the star schema benchmark test.
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed
Viewers will learn how the fundamental information of how to create a table.

724 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