i have a dimension named 'sdoc' which has 2 members
1) symptom word( first hierarchical level) and
2) doc id (second hierarchical level)
more than one 'symptom word' can have the same 'doc id'.
i want to know which all symptom words have a particular doc id (say 10.)
if i give [10].parent then it returns only the first parent whereas it actually has more than one parent.
how to retrieve all the parents.more than one 'symptom word' can have the same 'doc id'. So...there is a one-to-many relationship between 'doc id' and 'symptom word'?
if i give [10].parent then it returns only the first parent whereas it actually has more than one parent.So...there is a one-to-many relationship between 'symptom word' and 'doc id'?
Huh?
In database relationships, records normally have only one parent...
Please post the DDL code for the tables you are referencing, along with the SQL code you have tried.
Showing posts with label level. Show all posts
Showing posts with label level. Show all posts
Wednesday, March 21, 2012
retrieving parent(ascendants)
Labels:
ascendants,
database,
dimension,
doc,
hierarchical,
level,
members1,
microsoft,
mysql,
named,
oracle,
parent,
retrieving,
second,
server,
sql,
symptom,
word
Wednesday, March 7, 2012
retrieve the value that occurs the most
Hi,
I am trying to retrieve the value that occurs the most at a dimension level. For example, I have to analyze the product type mostly used in a specific target segment by number of products.
The mathematical function normally used is MODE. However, in AS2005 there is not such function. I tried to use TopCount but it is not as easy as I thought.
Any suggestion?
Thanks!
As far as I know, TopCount should work.
This is a sample from Adventure Works:
with
set [TopCustomers] as
TOPCOUNT(
[Dim Customer].[Dim Customer].[Dim Customer].members,
1,
[Measures].[Sales Amount]
)
select {[Measures].[Sales Amount]} on 0,
[TopCustomers] on 1
from [Adventure Works DW]
Hope this helps,
Santi
|||I think TopCount would only get you a mode if you were to use it against a count measure. I am guessing that you want to find out which member from the product dimension has the most transactions against it for a given set of criteria. Depending on the granularity of your dimensions you may have difficulty doing this without having some sort of count measure.
Subscribe to:
Posts (Atom)