MSSQL2005 Analysis Service Distinct Count

hi,
i am currently trying to build a distinct count on my cube (mssql2005 analysis services).
But after i added the discount count on the field i want to and start the processing, the following errors appear.
- Errors in the OLAP storage engine: The sort order specified for distinct count records is incorrect.
- Errors in the OLAP storage engine: An error occurred while processing the 'FACT VIEW STATISTIC' partition of the 'FACT VIEW  STATISTIC 1' measure group for the 'Accident Statistic' cube from the OLAP_PROJECT database.
the count measure works fine.
will appreciate any help on this distinct count problem.
thanks in advance.
HY

I also received this error:
"Errors in the OLAP storage engine: The sort order specified for distinct count records is incorrect. "
Running SQL Server 2005 SP2 Enterprise Edition
The collation between SQL Server and Analysis Services was the same.
The distinct count was on a character data type.
There were no NULLs in the data.
The cube was processing fine until new data was added.
After some investigation into the data it seems that the culprit was one row that the data length was 13 characters on the column of the distinct count. Everything else was less than 13 characters. (See results below). Updating this one row solved the problem. The exact value of the data is: '1-4296-175-9'
Here is a result set:
select len(columnname) as data_length, count(*) as count
from [tablename]
group by len(columnname)
order by data_length
data_length   count
2    3
5    1
6    3
7    2
9    1
10    856
13    1
My question though is if SQL2005 can do distinct counts on strings then why choke on one row with an extra length?

Similar Messages

  • Distinct count for multiple fact tables in the same cube

    I'm fairly new to working with SSAS, but have been working with DW environments for many years.
    I have a cube which has 4 fact tables.  The central fact table is Encounter and then I also have Visit, Procedure and Medication.  Visit, Procedure and Medication all join to Encounter on Encounter Key.  The relationship between Encounter
    and Procedure and Encounter and Medication are both an optional 1 to 1.  The relationship between Encounter and Visit is an optional 1 to many.
    Each of the fact tables join to the Patient dimension on the Patient Key.  The users are looking for a distinct count of patients in all 4 fact tables.  
    What is the best way to accomplish this so that my cube does not talk all day to process?  Please let me know if you need any more information about my cube in order to answer this.
    Thanks for the help,
    Andy

    Hi Andy,
    Each distinct count measure cause an ORDER BY clause in the SELECT sent to the relational data source during processing. In SSAS 2005 or later, it creates a new measure group for each distinct count measure(it's a technique strategy for improving perormance).
    Besides, please take a look at the following distinct count optimization techniques:
    Create Customized Aggregations
    Define a Processing Plan
    Create Partitions of Equal Size
    Use Partitions Comprised of a Distinct Range of Integers
    Distribute the Hash of Your UserIDs
    Modulo Function
    Hash Function
    Choose a Partitioning Strategy
    For more detail information, please refer to the article below:
    Analysis Services Distinct Count Optimization:
    http://www.microsoft.com/en-us/download/details.aspx?id=891
    In addition, here is a good article about SSAS Best Practices for your reference:
    http://technet.microsoft.com/en-us/library/cc966525.aspx
    If you have any feedback on our support, please click
    here.
    Hope this helps.
    Elvis Long
    TechNet Community Support

  • Report using Tabular Model and Measures based on Distinct Counts

    Hello,
    I am creating a report that should present something like this:
    YEAR-1 | MONTH-1 | MONTH-2 | MONTH-3... | YEAR | MONTH-1 | MONTH-2 | MONTH-3...
    My problem is that when designing the dataset to support this layout I drag the Year, Month and Distinct count Measure, but on the report when I want the value for the YEAR level I don't have it and I cannot sum the months value...
    What is the best aproach to solve this? Do I really have to go to advanced mode and customize my MDX or DAX? Can't basic users do something like this that seems so trivial and needed?
    Thank you
    Luis Simões

    Hi Luis,
    According to your description, you create a Reporting Services report using Analysis Service Tabular Model as the datasource, now what you want is sum the months value on year level, right?
    In your scenario, you can add the Month field to column group, add a parent group using Year Field and then add a Total on Month group. In this case, Reporting Services will sum the months value on Year level. I have tested it on my local environment, the
    screenshot below is for you reference.
    Reference:Lesson 6: Adding Grouping and Totals (Reporting Services)
    If this is not what you want, please describe your dataset structure, so that we can make further analysis.
    Regards,
    Charlie Liao
    TechNet Community Support

  • MeasureExpression property - Is there a possibility to implement distinct count with exclude empty?

    I have a measure which needs to have distinct count aggregation with exclude empty.
    Is there a possibility to specify MeasureExpression property to achieve the same? I have set the aggregation of the measure to none and I have typed the following function,
    Count(Distinct(Column_name),EXCLUDEEMPTY)
    where as the measure reads 0(zero) upon processing. Is there any other way to achieve this?
    The data feed has nulls included too for the column which this is to be achieved, which cannot be modified in the data level.
    Regards,
    Kantha Girish

    Hi Kantha,
    According to your description, you want to implement the distinct count aggregation, right? In this case, we can use a query like
    count(nonempty([DimName].[HierarchyName].[LevelName].members,[Measures].[MyMeasure]))
    Here are some blogs about how to implemet distinct count aggregation, please refer to the link below.
    http://blog.sqltechie.com/2009/09/distinctcount-analysis-service.html
    http://richardlees.blogspot.com/2008/10/alternative-to-physical-distinct-count.html
    If I have anything misunderstood, please point it out.
    Regards,
    Charlie Liao
    TechNet Community Support

  • [Forum FAQ] How do I create calculated measure using AMO in SQL Server Analysis Services?

    Introduction
    In SQL Server Analysis Services (SSAS), you can create a calculated measure in SQL Server Data Tool (SSDT)/Boniness Integrated Development Studio (BIDS). Sometimes you may need to create calculated measure by using AMO in a C# or VB project.
    In this article, I will demonstrate so how to create calculated measure using AMO in SSAS?
    Prerequisites
    Before create calculated measure using AMO, you need to ensure that the following components were installed in your server.
    The multidimensional database AdventureWorks Multidimensional Model 2012
    A SQL Server with SSIS and SSAS installed
    The AMO libraries installed:
    X86 Package (SQL_AS_AMO.msi)
    X64 Package (SQL_AS_AMO.msi)
    Solution
    Here is the detail steps to create calculated measure using AMO in SSAS.
    Open SSDT and create a new SSIS project.
    Drag Script Task to the design surface.
    Click SSIS-> Variables to open the Variables window and add two variables that used to connect to the server and database.
    Create a connection to connect to SSAS server.
    Rename the connection name to ssas.
    Double click the Script Task to open Script Task Editor.
    Add Connection and Database variables to ReadWriteVariables textbox and then click Edit Script button.
    Add AMO reference in the Solution Explore window.
    Copy the script below and paste it into the script.
    Dim objServer As Server
    Dim objDatabase As Database
    Dim strDataBaseID As String
    Dim objCube As Cube
    Dim objMdxScript As MdxScript
    Dim objCommand As Command
    Dim strCommand As String
    objServer = New Server
    objServer.Connect("localhost")
    objDatabase = objServer.Databases("AdventureWorksDW2012Multidimensional-EE2")
    strDataBaseID = objDatabase.ID
    If objDatabase.Cubes.Count > 0 Then
    objCube = objDatabase.Cubes("Adventure Works")
    If objCube.MdxScripts.Count > 0 Then
    objMdxScript = objCube.MdxScripts("MdxScript")
    objMdxScript = objCube.MdxScripts(0)
    Else
    objCube.MdxScripts.Add("MdxScript", "MdxScript")
    objMdxScript = objCube.MdxScripts("MdxScript")
    End If
    objCommand = New Command
    strCommand = "CREATE MEMBER CURRENTCUBE.[Measures].[Multipy Measures By 3]"
    strCommand = strCommand & " AS [Measures].[Internet Sales Amount] * 3, "
    strCommand = strCommand & " VISIBLE = 1 ; "
    objCommand.Text = strCommand
    objMdxScript.Commands.Add(objCommand)
    objMdxScript.Update()
    objCube.Update()
    End If
    objServer.Disconnect()
    Then you can run this SSIS package to create the calculated measure.
    Applies to
    Microsoft SQL Server 2005
    Microsoft SQL Server 2008
    Microsoft SQL Server 2008 R2
    Microsoft SQL Server 2012
    Please click to vote if the post helps you. This can be beneficial to other community members reading the thread.

    Thanks,
    Is this a supported scenario, or does it use unsupported features?
    For example, can we call exec [ReportServer].dbo.AddEvent @EventType='TimedSubscription', @EventData='b64ce7ec-d598-45cd-bbc2-ea202e0c129d'
    in a supported way?
    Thanks! Josh

  • Running Total & Distinct Count Query

    Crystal 10.0.0.533 CR Professional
    Hope you can assist.
    I have a report listing deals signed, each deal has a corresponding category i.e. industry type, Accountant, Chiropractor, Financial Services, etc.
    I am undertaking a Distinct Count on these categories so that in the group footer it is showing number of different categories signed in a period (the report is grouped into different date periods). This is working OK.
    However, I need to EXCLUDE the category from this distinct count if the deal value is zero.
    I have tried using a formula to show a blank field if the value is zero, however it appears to be distinctly counting the blank as a category?
    Any assistance would be much appreciated.
    Tracy

    Deffinetly it will be less than what you expect for grand total. It is because when you are calculating distinct count for each group suppose
    Group A has categories A,B,C,D-->distinct count (4)
    Group B has C,D,E,F-->distinct count (4)
    but while calculating grand total then the distinct count will be
    A,B,C,D,E,F --> grand total (6) but not (8).
    In this case you need to use mannual running total like this
    whileprintingrecords;
    numbervar i;
    i:=i+{running total};
    place this in group footer and create another fomula like this
    whileprintingrecords;
    numbervar i;
    place this in report footer to get the correct grand total.
    Regards,
    Raghavendra

  • Distinct Count Function-how to use properly

    Hello,
    I am new to using forums & have only been using Crystal since May of 2009, so i hope i do this correctly & provide the appropriate information.  i've looked for this answer in what's been posted but cannot find it.  Some things i've read I don't really understand.  I only know how to use the functions that are in the software, i don't know how to write them myself (i think that's when people have referred to SQL code or basic syntax)
    I have CR Professional, version 11.0.0.1282 (Crystal Reports XI).
    I work at a county health dept and we have a annual medicaid cost report,  I am linking Crystal to our EMR billing module.  i have my report sorted by insurance, ie medicaid, bcbs, abw, hpm etc.  and within each ins group i have the clients ID, DOS (date of service), procedure code, charge amt, ins pmt & patient pmt.  i have totaled the charges & pmts for each group-works fine.  i even have been able to create the formula to adj out the duplicate entries in the billing module (a service was entered wrong then adjusted out then re-entered correctly-without my formula crystal was pulling both these records and adding them to total charges.)
    Where my problem lies and what my question is:  I need to count encounters, an encounter is the visit, but each visit could have 2 or more procedure codes.   So this results in multiple lines on my report for one visit, which i want for the charges to add correctly, but it makes my visit count to high. So I read about the distinct count function, of which there are three listed & i'm having a hard time understanding the differences.  What i tried is: a distinct count of the acct ID-so the same acct ID's are only counted the one time.  But some clients see us more than once per year, meaning the acct ID is the same but the DOS is different.  For this client that would be 2 visits.  But crystal is counting this as 1.
    Saying what i want to do is this:  Count as 1 when the acct ID and DOS are the same.  I've tried using the different distinct counts but when i check my formula it always has errors.  So I'm sure my lack of knowledge is what's holding me up-i fully believe crystal can do this.
    Any help would be greatly appreciated.

    I create a dummy table, set up acc_id and DOS and Charge.
    Created a running total
    Summarized acc_id
    Type of summary Count
    Evaluated using a formula
         <> previous ()
    and reset on ACC_ID
    My groups were sorted by acc_id and date
    where there were multiple visits on the same DOS my count was 0
    where the dos changed it would count accordingly.
    You may need to use two Running totals to get the complete picture.

  • Analysis service Tabular Model

    Hi
    Help me anyone,
    I Have to calculate for 1 Year rolling values from current date 
    example let say i am in march-2014   i have to rolling my column values for 1 year means April-2013 
    For this what function should i use 
    and also one more thing I have a string values in my column like
    Status
    Active
    Seperated
    Active
    Seperated
    Resigned
    Resigned
    Abscond
    Abscond 
    I need to apply 1 year rolling formula on this column 
    how should i get these total count  for 1 year rolling
    Please help me on that 
    Please reply me soon
    Sreeni
    Sreeni

    Hi Sreeni,
    Since this issue is related to Analysis Services, I will move this thread to
    Analysis Services forum. Sometime delay might be expected from the job transferring. Your patience is greatly appreciated. 
    Thank you for your understanding and support.
    Regards,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • Analysis Services 2012 hungs up

    Hi everybody,
    I am using sql server 2012 sp2, 16 cores CPU, 128 Gb Memory.
    Both sql server and analyis servics are installed on the same server.
    sql server is allocated to use  (60 Gb). And analysis services instance properties are set to default values.
    I have a cube which is accessed by multiple applications ( excel pivot , java applications).
    the cube works fine when less number of users connects to it . But it start cribbing when multiple user connect to it .the server doesn't respond .
    From java application when one user runs the tool it hits around 2000 mdx queries of similar nature with only where condition is changed.similarly it might happens that during peak load it is expected to 20 users to use the java application and fires queries
    against cube so totally (20*2000 number of queries).
    also the same mdx queries when run from ssms will not take much time, it respond in ms when checked in (mdx editor).
    Other details:
    the cube is partitioned to 36 months, andwe have created UBO on the maximum queries fired on Analysis DB. THE CUBE IS SCHEDULED TO PROCESS EVERY 15 MIN.
    Please share me your thoughts.
    Below is the counter Captured
    Thanks
    Prasanna KJ
    Praxy

    Hi Praxy,
    Thank you for your question. 
    I am trying to involve someone more familiar with this topic for a further look at this issue. Sometime delay might be expected from the job transferring. Your patience is greatly appreciated. 
    Thank you for your understanding and support.
    Regards,
    Charlie Liao
    TechNet Community Support

  • Refreshing the Data Source View in Analysis Services

    I have added columns to the SQL Database table that is used as a dimension in an Analysis Services Cube.  The new columns will be used as additional Property Fields for the dimension.  When I attempted to refresh the Data Source view so that the additional columns are present, I am given the following error:
    System.Data
    Property not accessible because 'Parent Columns and Child Columns don't have type-matching columns'
    I have done nothing to the columns used for the parent of child and the error message provides nothing to gon on. Does anyone have any ideas on this?
    Gary

    Olga,
    Thanks for your response.  I will try and answer your questions
    1) I have not tried removing the columns yet.  I will try that this afternoon but have limited hope.  The two columns I added are simple text columns that will be used as attributes in the dimension.  I have made no change to the parent or child columns.
    2) The table I modified is the source table for a parent-child dimension.
    3) The reference to the "check list" does not take me to any kind of check list.
    4) The parent-child dimensions I am trying to modify have been in use for months and the parent and child columns do have the dame data types.
    5) I have also check the data types between the dimension table and the fact table.  they use the same data types (small int).
    6) I have not made a collection for the parent key, it is a single column. The remainder of your last paragraph is not clear to me. Can you give me an example.
    I am fairly inexperienced with Analysis Services, please talk slow and use small words  :-)
    Thanks again for your help!
    Gary

  • Distinct count of GRN's in Query PLD

    hi all,
    We have developed a daily grn report and designed report
    using  Query PLD.
    Report contains
    (grn no,date,vendor name,vendor ref no,item code,item
    description,quanity & line total)
    We want to display no of grn's(distinct count)
    @ repetitive area footer.
    Is there any function available in formula field to display
    distinct count of no. of grn's ? / It should done thru query.
    Thanks,
    with regards,
    A.Jeyakanthan

    it will be hard from PLD, instead u can have ur query like,
    SELECT 'Details', '   ',T0.Docnum, T0.CardName, .... FROM OPDN T0 WHERE Month( T0.DocDate ) = Month ('{%0]')
    Union
    SELECT 'Counts', count(T0.DocNum) as 'Doc(s) No', ' ', ' ', ... FROM OPDN T0 WHERE Month( T0.DocDate ) = Month ('{%0]')
    (Replace { with [ )
    Note ' ' is a gap in order to fill the other fields. in first query have given tht '  ' gap purposely so tht the display will not affect ur designing part
    union is used b'coz Count() fn is like aggregate, so wont allow further individual fields coming along with it.
    the 2nd query will occupy only one row, which by grouping u can separate and can hide from repetitive and take the value via formula field by writing that field's id to it into Footer Area.
    Regards,
    Dhana.
    Edited by: Dhanalakshmi C on Mar 5, 2008 1:31 PM

  • Unable to start Web Analysis .Service Temporarily Unavailable

    Hi,
    I am using the following URL to access Web Analysis http://testdb.xxx.xxx.xx:19000/WebAnalysis/WebAnalysis.jsp. But it throws up the following error -
    "*Service Temporarily Unavailable, the server is temporarily unable to service your request due to maintenance downtime or capacity problems. Please try again later.*"
    FYI
    1. I'm using EPM 11.1.1.3 on Linux Server (Tikanga)
    2. Planning, Shared Services, Workspace, Essbase etc. are working fine. The problem is only with Web Analysis. However, even Web Analysis was working fine in the not-so-distant past.
    I have tried stopping and starting the Web Analysis service but that doesn't seem to help.
    Any ideas would be appreciated.
    Thanks & Cheers,
    Sahil

    Just to add to my first post, i am facing the following issues:
    1. When I restart the Web Analysis service
    [hypappl@testdb bin]$ cd /oracle/hyp/app/deployments/Tomcat5/bin
    [hypappl@testdb bin]$ ./startWebAnalysis.sh restart
    WARNING: Access to a frame buffer device, or virtual frame buffer device
    is required for chart rendering. DISPLAY is not currently set.
    Please modify /oracle/hyp/app/deployments/Tomcat5/bin/setCustomParamsWebAnalysis.sh.
    WARNING: Access to a frame buffer device, or virtual frame buffer device
    is required for chart rendering. DISPLAY is not currently set.
    Please modify /oracle/hyp/app/deployments/Tomcat5/bin/setCustomParamsWebAnalysis.sh.
    WARNING: Access to a frame buffer device, or virtual frame buffer device
    is required for chart rendering. DISPLAY is not currently set.
    Please modify /oracle/hyp/app/deployments/Tomcat5/bin/setCustomParamsWebAnalysis.sh.
    Using CATALINA_BASE: /oracle/hyp/app/deployments/Tomcat5/WebAnalysis
    Using CATALINA_HOME: /oracle/hyp/app/common/appServers/Tomcat/5.5.17
    Using CATALINA_TMPDIR: /oracle/hyp/app/deployments/Tomcat5/WebAnalysis/temp
    Using JRE_HOME: /oracle/hyp/app/common/JRE/Sun/1.5.0
    2. When I start service from biplus folder
    [hypappl@testdb bin]$ cd /oracle/hyp/app/products/biplus/bin
    [hypappl@testdb bin]$ ./start.sh restart
    WARNING: Access to a frame buffer device, or virtual frame buffer device
    is required for chart rendering. DISPLAY is not currently set.
    WARNING: Access to a frame buffer device, or virtual frame buffer device
    Please modify /oracle/hyp/app/deployments/Tomcat5/bin/setCustomParamsFinancialReporting.sh.
    is required for chart rendering. DISPLAY is not currently set.
    Please modify /oracle/hyp/app/deployments/Tomcat5/bin/setCustomParamsWebAnalysis.sh.
    WARNING: Access to a frame buffer device, or virtual frame buffer device
    is required for chart rendering. DISPLAY is not currently set.
    Please modify /oracle/hyp/app/deployments/Tomcat5/bin/setCustomParamsWebAnalysis.sh.
    3. When I run the setCustomParamsWebAnalysis.sh
    [hypappl@testdb bin]$ ./setCustomParamsWebAnalysis.sh
    WARNING: Access to a frame buffer device, or virtual frame buffer device
    is required for chart rendering. DISPLAY is not currently set.
    Please modify .
    WARNING: Access to a frame buffer device, or virtual frame buffer device
    is required for chart rendering. DISPLAY is not currently set.
    Please modify .
    WARNING: Access to a frame buffer device, or virtual frame buffer device
    is required for chart rendering. DISPLAY is not currently set.
    Please modify .
    4. And finally, when I try to open Web Analysis reports from Workspace -> Explore, I get the below error
    Required application module analyzer.reportview is not configured. Please contact your administrator.
    Web Analysis was working just fine until recently. Now the problem is only with WA. Everything else is working as it should If nothing gets Web Analysis up and running again, is there a way I can retrieve my saved report files? I can view these files from Workspace -> Explore -> Reports folder.
    Thanks,
    Sahil

  • MS SQL database needs to run mdx query to analysis services to retrieve data from a BPC 10 Netweaver cube(view only)

    We are in the process of migrating from BPC7 SP12 Microsoft sql server to BPC10 netweaver on a sql server with BW7.4 and need to integrate our home grown data warehouse which is on a Microsoft sql server.  The data warehouse currently connects to BPC7 using integration services/analysis services and runs mdx queries to analysis services to retrieve data from the BPC7 cube (view only).  Please provide documentation on how to create this same integration with our data warehouse using BPC10 netweaver on a sql server.

    When you were setting up your ODBC data source for
    the Text driver, did you click on the "Options"
    button? There's a lot of options in there that I
    didn't understand at first glance.Yes I clicked on the options button, but the only thing there is dealing with file extensions. I left it set to the default.
    I have since tried closing my connection after I insert a record, I then try executeQuery, but still no luck. Seems strange that I can write to the file but not read from it. If any thing I'd expect the opposite problem.
    I have also tried using the class "JoltReport" from the sun tutorial instead of my own with the same result.
    Message was edited by:
    Hentay

  • How to get Distinct Count of Products across two dimensions

    Hi,
    I have two dimensions, Item and Presentations. I need to get distinct count of products for IMD_Id + Merc_Pres_Id. IMD_Id is the lowest member in Item and Merc_Pres_Id is lowest in Presentation. My MDX query is given below but when I apply filters to
    slice it, it does not work and does not give right count. It always gives the count for all.
    /* Last Year Demand - Demand for 12 months back of selected months */
    With
    Member [Measures].[LYDemand]
    as
    Sum(
    Generate(
    EXISTING[All Date].[Fiscal Month Name].[Fiscal Month Name].Members,
    {parallelperiod([All Date].[Fiscal Month Name].[Fiscal Month Name], 12
    ,[All Date].[Fiscal Month Name].CurrentMember)}
    ,[Measures].[Proj Demand]
    /* Last to last Year Demand - Demand for 24 back of selected months */
    Member [Measures].[LLYDemand]
    as
    Sum(
    Generate(
    EXISTING[All Date].[Fiscal Month Name].[Fiscal Month Name].Members,
    {parallelperiod([All Date].[Fiscal Month Name].[Fiscal Month Name], 24
    ,[All Date].[Fiscal Month Name].CurrentMember)}
    ,[Measures].[Proj Demand]
    /* Current Year Active Products */
    Member [Measures].[CYCount]
    as
    CASE
    WHEN
    [Measures].[Proj Demand] > 0
    THEN
    DistinctCount(Existing(([All Items].[IMD Id].[IMD Id],[All Merchandise Presentations].[Merch
    Pres Key].[Merch Pres Key])))
    ELSE
    NULL
    END
    /* Last year Active Products */
    Member [Measures].[LYCount]
    as
    CASE
    WHEN
    [Measures].[LYDemand] > 0
    THEN
    DistinctCount(([All Items].[IMD Id].[IMD Id],[All Merchandise Presentations].[Merch Pres Key].[Merch Pres
    Key], [All Items].[Style Name].CurrentMember, (StrToMember('[All Date].[Fiscal Month Name].&[201401]',CONSTRAINED).Lag(12)
    : StrToMember('[All Date].[Fiscal Month Name].&[201411]',CONSTRAINED).Lag(12))))
    ELSE
    NULL
    END
    /* Last to last Year Active Products */
    Member [Measures].[LLYCount]
    as
    CASE
    WHEN
    [Measures].[LLYDemand] > 0
    THEN
    DistinctCount(([All Items].[IMD Id].[IMD Id],[All Merchandise Presentations].[Merch Pres Key].[Merch Pres
    Key], [All Items].[Style Name].CurrentMember, (StrToMember('[All Date].[Fiscal Month Name].&[201401]',CONSTRAINED).Lag(24)
    : StrToMember('[All Date].[Fiscal Month Name].&[201411]',CONSTRAINED).Lag(24))))
    ELSE NULL END
    SELECT
    [Measures].[CYCount], [Measures].[LYCount], [Measures].[LLYCount],
    [Measures].[Proj Demand],[Measures].[LYDemand],[Measures].[LLYDemand]
    ON
    COLUMNS,
    Non
    Empty([All Items].[Demand Center Name].[Demand Center Name], [All Items].[Style Name].[Style Name])
    ON ROWS
    FROM
    (SELECT (StrToSet('[All Items].[Style].[ALL]'))
    ON COLUMNS
    FROM
    (SELECT (StrToSet('[All Items].[Demand Center].[ALL]'))
    ON COLUMNS
    FROM
    (select (STRTOSET('[All Items].[Merch Group].&[MG-110]'))
    on Columns
    FROM
    (SELECT (StrToSet('[All Merchandise Presentations].[Merch Pres Chnl Dkey].&[MPC-1]'))
    ON COLUMNS
    From
    [FMI Forecasting]
    WHERE {strToMember('[All Date].[Fiscal Month
    Name].&[201401]',CONSTRAINED) :
    StrToMember('[All Date].[Fiscal Month Name].&[201411]',CONSTRAINED)}
    Requirements are as follows:
    1. Distinct Count should not include products where Proj Demand is 0, when I am using Filter function to remove products with 0 demand, query is really slow and execution time goes up from 35- 40 secs to 8-9 Minutes.
    2. When we apply filter (parameters) Distinct Count should be in the context of filters( which are mentioned in the select statement like Style, Demand Center and Merch Group). Currently after applying filters count does not change.
    Thanks for help.

    Hi Skd78,
    Thank you for your question. 
    I am trying to involve someone more familiar with this topic for a further look at this issue. Sometime delay might be expected from the job transferring. Your patience is greatly appreciated. 
    Thank you for your understanding and support.
    Regards,
    Charlie Liao
    TechNet Community Support

  • What permission required to Browse Cube in Analysis Services.

    Hi 
    I have a request where user want to browse cubes in SSMS for analysis services. I dont want to give him (Full control administrator) . when i tried other permission read / process data then he is not able to browse cube.
    Even if give him full control role then while rebuilding cube these permissions will removed.
    How can i give user access to just view cube , there meta data , objects in ssms
    Thanks Saurabh Sinha
    http://saurabhsinhainblogs.blogspot.in/

    Hi Saurabh,
    According to your description, you are trying to grant browser permission to the users without success, right?
    Roles are used in Microsoft SQL Server Analysis Services to manage security for Analysis Services objects and data. Cube access by a non-administrator requires membership in a role created for the database containing the cube. Membership is supported
    for Windows user or group accounts, defined in either Active Directory or on the local computer.
    So in your scenario, please ensure that the grant permission steps are correct, you can refer to the links below to do it.
    http://technet.microsoft.com/en-us/library/ms174840(v=sql.110).aspx
    http://msdn.microsoft.com/en-in/library/ms174799.aspx
    Regards,
    Charlie Liao
    TechNet Community Support

Maybe you are looking for

  • Premiere CS6 keeps crashing when i try to add movement to a Tif file

    Hi, I'm running Premiere 6.02 on a MacBook Pro running 10.8.4 with 16Gb of RAM. I have a simple project on a timeline, but each time I add a Tif file and try to add a little movement to the image using scaling in the Motion video effects, Premiere cr

  • Why can i not install iso 4 on my iphone 4, says empty files, is this on my pc or on iphone ? thanks for help

    When i try to update my iphone 4, it will not let me as it says i need to empty recycle bin and files is this on my iphone or pc, very confused Thanks in advance

  • Oracle9i Export Problem with NCHAR

    Hi, I have a schema in database (Oracle 9.2.0.7 running on SuSeLinux 9) having following nls parameters NLS_CHARACTERSET WE8ISO8859P1 NLS_NCHAR_CHARACTERSET AL16UTF16 Now, i want to export the schema with NLS_CHARACTERSET set to AL32UTF8 and NLS_NCHA

  • Remove pictures in Lync

    I'm using Lync 2013, and even though I've changed the Options -> Personal to say that I don't want to see pictures, Lync still shows a silly cartoon picture next to people when I'm having a conversation with them, next to their name. We're wanting to

  • Rotate 3D interfering with state reset?  *help*

    I have several shapes (in photoshop) that transition between states... size, location, opacity, etc. One of the shapes has a manually applied action "Rotate 3D" on the transition from State 1 -> State 2. I have 2 buttons.  A "Next Button" that moves