Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 mdx query - SELECT ORDER

Author  Topic 

m1k3ch3ck
Starting Member

7 Posts

Posted - 2012-06-12 : 07:03:11
hey guys,

i am currently working myself through our scripts which we got from our university for our database/mdx subject.
i got a question, which i will ask the following way, since this is the way i encountered it:
- show you how i understood a scenario (image 1)
- show you how i tried to use my understanding of this scenario on another query (image 2), but dont understand it, which leads into my question

both screenshots show the (correct) query and what it (does successfully) show when using the query. i got problems understanding the queries.

here the first one:

the way i understood this query is:
telling "the red marked part defines how the query should be sorted. it is sorted ascending by the measures.absatzmenge, which is 16,78,86,134, which is correct.

what i now tried is to understand the following query:


my solution/guess was:
select order ( artikel.artnr.children, asc ) on 0, ....

but the solution from our papers (see screenshot) say:
select order (artikel.artnr.children, tupleToStr(artikel.artnr.currentMember, asc) on 0, ...

how my question:
red marked command neccessary ?

thanks a lot in advance

   

- Advertisement -