Using MDX query in RPD

I have a MDX query that I want to use in the RPD as "Table Type" =Select
I did create a new object as "Physical Dimension" and gave the below script as Essbase 11 specific SQL, but this does not work and an getting the generic error "[nQSError: 15002] Missing navigation space for subject area test. (HY000)". Any Idea as to how to use the MDX in RPD?
MDX Script:
with set classes as '{[Class_Data],[Inventory_Class_Data]}'
set ledgers as '{[Actuals_Ledger],[Finance_Ledger],[Reclass_Ledger],[Allocation_Ledger],[Blending_Ledger],[HCSADJ_Ledger]}'
set bu as '{[UTHCS],[UTMBG],[CONSL]}'
set account as 'Except ({filter ([Accounts].Levels(0).members, IsAncestor([SRECNA],[Accounts].CurrentMember)),
filter ([Accounts].Levels(0).members, IsAncestor([MISC_AUDIT],[Accounts].CurrentMember)),
                                  filter ([Accounts].Levels(0).members, IsAncestor([SNA],[Accounts].CurrentMember))},{[Change in Net Assets and Restatements]})'
set funds as '{filter ([Fund].Levels(0).members,IsAncestor([All_Funds],[Fund].CurrentMember)),
filter ([Fund].Levels(0).members,IsAncestor([Do Not Use Funds],[Fund].CurrentMember))}'
select {[Act]} on columns,
Non Empty (CrossJoin(CrossJoin(
CrossJoin(account,funds),
CrossJoin(ledgers,bu)
),classes)
  ) on rows
from [finrpt15.work]
where (FY15,YTD_Apr,UTMB_INSTITUTION);
Thanks,
Ravi

Hi BIGUY,
Multidimensional Expressions (MDX) is the query language that you use to work with and retrieve multidimensional data in Microsoft Analysis Services. MDX is based on the XML for Analysis (XMLA) specification, with specific extensions for SQL Server Analysis
Services.
According to your description, it's hard to give your the exact MDX query to pull the data which you want from the cube since there are no any detail information about the cube. Here are some basic knowledge for your reference.
Querying Multidimensional Data with MDX
MDX Sample
Regards,
Charlie Liao
TechNet Community Support

Similar Messages

  • Except function with parent child hierarchy using mdx query

    HI,
    I need to remove some items using mdx query in parent child hierarchy.
    I tried with below query,it is not removeing ,could you please help me.
    SELECT
    {[Measures].[Amount]} ON
    COLUMNS
     NonEmpty([Account].[Accounts].[Account Level 01],[Measures].[Amount])
    ON ROWS
    FROM (SELECT
    -Descendants({[Account].[Accounts].&[47]},,Leaves)
    } ON COLUMNS
    FROM [Adventure Works])
    indu

    Hi Indu,
    Why do you remove some itmes using
    Descendants function? Generally, we use FILTER function to achieve the requirement.
    WITH SET [CustomAccounts] AS
    FILTER ([Account].[Accounts].[Account Level 01].Members , [Account].[Accounts].CurrentMember.Name<>'Net Income')
    SELECT {[Measures].[Internet Sales Amount]} ON 0
    [CustomAccounts] ON 1
    FROM [Adventure Works]
    WITH SET [CustomAccounts] AS
    FILTER ([Account].[Accounts].[Account Level 01].Members , [Account].[Accounts].CurrentMember.Name='Net Income')
    SET [RemainingAccount] AS
    [Account].[Accounts].[Account Level 01]- [CustomAccounts]
    SELECT {[Measures].[Reseller Sales Amount]} ON 0
    [RemainingAccount] ON 1
    FROM [Adventure Works]
    Results.
    References.
    http://www.databasejournal.com/features/mssql/article.php/3306101/MDX-Essentials-Basic-Set-Functions-The-Filter-Function.htm
    http://social.msdn.microsoft.com/Forums/sqlserver/en-US/c0149678-97f2-4066-903f-7f9e9ff09b56/filtering-out-dimension-members-with-mdx?forum=sqlanalysisservices
    Regards,
    Charlie Liao
    If you have any feedback on our support,
    please click here.
    Charlie Liao
    TechNet Community Support

  • IIf condition between dates using mdx query

    Hi,
    how to check IIF condition between dates using mdx query.
    I able to check single year,plese check below mdx query.I need to check members between years.
    my requirement is member is belongs to between years(2007 to 2010),display "yes" else "NO";
    Could you please give me exact mdx query.
    From,to-2007,2010,if member belongs to 2007to 2010 then disply "yes"else "no".
    how to pass two members in IIf condition.
    WITH
    MEMBER Measures.[test]
    AS Iif([Date].[Calendar Year].currentmember
    is [Date].[Calendar Year].&[2007],"no","yes")
    SELECT {Measures.[test]}
    on 0
    ,[Product].[Subcategory].[Subcategory].MEMBERS * [Date].[Calendar Year].[Calendar Year]
    ON 1
    FROM [Adventure Works]
    indu

    Hi Sriindu,
    consider the following:
    WITH
    MEMBER measures.[test] AS
    IIF
    Exists
    [Date].[Calendar Year].CurrentMember
    [Date].[Calendar Year].&[2007] : [Date].[Calendar Year].&[20010]
    ).Item(0)
    IS
    [Date].[Calendar Year].CurrentMember
    ,"yes"
    ,"no"
    SELECT
    {measures.[test]} ON 0
    [Product].[Subcategory].[Subcategory].MEMBERS
    [Date].[Calendar Year].[Calendar Year] ON 1
    FROM [Adventure Works];
    Philip,

  • Using mdx query from Java Apache

    Please suggest/guide me how to use MDX query to pull data from cube from Apache JAVA??
    BI GUY

    Hi BIGUY,
    Multidimensional Expressions (MDX) is the query language that you use to work with and retrieve multidimensional data in Microsoft Analysis Services. MDX is based on the XML for Analysis (XMLA) specification, with specific extensions for SQL Server Analysis
    Services.
    According to your description, it's hard to give your the exact MDX query to pull the data which you want from the cube since there are no any detail information about the cube. Here are some basic knowledge for your reference.
    Querying Multidimensional Data with MDX
    MDX Sample
    Regards,
    Charlie Liao
    TechNet Community Support

  • Date parameters using MDX query

    Hello experts,
    Not sure if this question falls under SSAS or SSRS but I'm writing it here for now and hopefully get the answer.
    I'm using SSAS cube to develop a report using SSRS and this is the first time I'm doing it. I want to filter records based on date range and did some research online. My report contains two datasets:
    1. dsMain dataset -> it contains all the field which I want to use in the report and added a parameter thru query designed with following settings:
    Dimension : Dates
    Hierachary : Date
    Operator : Range (Inclusive)
    Parameters : checked
    it created two parameters called FromDatesDate and toDatesDate
    2. I created another dataset called dsDate and wrote a custom query (found at following link) and changed FromDatesDate and ToDatesDate using this date dataset
    https://jsimonbi.wordpress.com/2011/03/22/using-a-date-parameter-in-ssrs-with-mdx/
    Query for dsDate
    WITH
    MEMBER DateValue
    AS
       [Dates].[Date].CurrentMember.UniqueName
    MEMBER DateLabel
    AS
       [Dates].[Date].CurrentMember.Name
    SELECT
        [Measures].[DateValue],
        [Measures].[DateLabel]
    } ON 0,
         [Dates].[Date].[Date]
    } ON 1
    FROM [myCube]
    Here is the value returned by dsDate dataset (above query)
                            DateValue                          DateLabel
    06/04/1980 [Dates].[Date].&[29375]
    06/04/1980
    06/05/1980 [Dates].[Date].&[29376]
    06/05/1980
    06/06/1980 [Dates].[Date].&[29377]
    06/06/1980
    06/07/1980 [Dates].[Date].&[29378]
    06/07/1980
    06/08/1980 [Dates].[Date].&[29379]
    06/08/1980
    06/09/1980 [Dates].[Date].&[29380]
    06/09/1980
    06/10/1980 [Dates].[Date].&[29381]
    06/10/1980
    06/11/1980 [Dates].[Date].&[29382]
    06/11/1980
    06/12/1980 [Dates].[Date].&[29383]
    06/12/1980
    06/13/1980 [Dates].[Date].&[29384]
    06/13/1980
    Here is what I changed in FromDatesDate and ToDatesDate parmeter:
    Under Available Values tab:
    Dataset : dsDate
    Value Field : DateValue
    Label Field : DateLabel
    Here are my questions:
    1. I want to use date/time parameter so that user doesn't have to scroll thru whole date dimension.
    2. I changed the FromDatesDate and ToDatesDate to date/time parameter, removed the values from Available values tab and made the following changes on Parmaeters expression under dsMain dataset
    =”[Dates].[Date].&[” + Format(CDate(Parameters!FromDatesDate.Value),”MM/dd/yyyy”)
    + “T00:00:00]”
    =”[Dates].[Date].&[” + Format(CDate(Parameters!ToDatesDate.Value),”MM/dd/yyyy”)
    + “T00:00:00]”
    Now when I run the report I get following error:
    Query (1, 55) The restrictions imposed by the CONSTRAINED flag in the STRTOMEMBER function are violated.
    I think the reason is by changing parameter to date/time, now I cannot get "DateValue" which is required for the query.
    1. What is the best way to work with date parameters?
    Hope it is all clear and look forward to hear from experts.
    Thanks,
    P
    mark it as answer if it answered your question :)

    Hi Parry2k,
    In Analysis Services, a member can be referenced by either its member name or by its member key. The member key is used by the dimension to specifically identify a given member. The ampersand (&) character is used in MDX to differentiate
    a member key from a member name. In this scenario, the datetime is member name, not the member key. So you should not add "&".
    Reference:
    Member Names and Keys
    Simon Hou
    TechNet Community Support

  • SSRS report using mdx query to display sales of product by yearwise

    There is a requirement to create SSRS report as 
    Product                         +Calender2011               -Calender 2012            +Calender 2013      
             + Calender 2014
    Jan12 Feb12 Mar12...
    Product 1 50    100       200 ..
    Product 2 150    900       200 ..
    Product 3 250    180       900 ..
    Product 4 450    100       200 ..
    Product 5 50    100       200 ..
    Product 6 50    100       200 ..
    When I click on Calender2011 corresponding all months of 2011 has to appear and likewise for Calender2012, CalenderN 
    The MDX query I have like as follows-
    Select    Non Empty{
    [Measures].[Product1], 
     [Measures].[Product2], 
     [Measures].[Product3], 
     [Measures].[Product4],
      [Measures].[Product5], 
      [Measures].[Product6], 
      [Measures].[Product7], 
      [Measures].[Product8], 
      [Measures].[Product9], 
      [Measures].[Product10], 
      [Measures].[Product11], 
       } ON Rows ,
       Non Empty  { ([Dim Calendar H].[Year Name].[Year Name] ) *([Dim Calendar H].[Month name].[Month name])
     ON COLUMNS
      FROM ( SELECT ( { [Dim Calendar H].[Year Name].&[Calendar 2014], 
     [Dim Calendar H].[Year Name].&[Calendar 2013], 
     [Dim Calendar H].[Year Name].&[Calendar 2012], 
     [Dim Calendar H].[Year Name].&[Calendar 2011] } ) 
     ON COLUMNS 
     FROM [Cube]) 
    Please help me. 
    Advance thanks...

    Hi Afans,
    According to your description, you want to create a drill-down report using SQL Server Analysis Services database, right?
    In this case, you need add the Year and Month fields to the column group, and set the Month column can be toogled by Year column group. I have teste it on my local environment, here is the sample query for your reference.
    select [Measures].[Internet Sales Amount] on 0,
    [Product].[Category].members*[Date].[Calendar].[Calendar Year].members*[Date].[Month of Year].members on 1
    from
    [Adventure Works]
    Reference
    http://popbi.wordpress.com/2012/03/02/ssrs-how-to-add-a-column-group-to-an-existing-table/
    http://msdn.microsoft.com/en-IN/library/dd207042.aspx
    Regards,
    Charlie Liao
    TechNet Community Support

  • How to compare MoM using MDX Query

    Hello,
    I have a cube which I want to use  to compare MoM. 
    Example:
    Start Date : Jan 1 2015
    End Date : Jan 31 2015
    compare again Dec 1 2014 and Dec 31 2014
    Report will look like like:
                              Sales
                              Jan 1 - Jan 31 2015            Dec 1 - Dec 31 2014     Variance              % Variance
    Product A               100                                       200                  
         -100
    Product B                50                                         40              
                10
    Wondering how this can be achieved SSAS.
    Thanks,
    P
    mark it as answer if it answered your question :)

    Hello,
    Thanks for the reply. I is surely helpful but here is the next challenge I have in this:
    Just to give a run down, let's say user want to run a data for following date and want multiple comparison based on the date:
    For example date entered by user is Jan 14, 2015 and he want to see the data
    Jan 01 - Jan 14th  for the MTD For Jan 2015
    Dec 01 - Dec 14th for previous month
    Oct 16 2014 to Jan 14 2015 (previous 90 days from Jan 14 2015)
    Sep 15 2014 to Dec 14 2014 (previous 90 days from last date of previous month which is Dec 14th in this case)
    Just wondering if this kind of date range can be calculated on fly to get the data.
    Thanks,
    P
    mark it as answer if it answered your question :)

  • Simple sql to mdx query using the max fn

    I'm using the MDX Max fn to get the max of a certain value but now I want get max for a certain pair of values and not all, how could i write this in mdx as a calculation?
    More details: For a certain pair of status and substatus (status=1, substatus=1) from a trans dimension table i want to get the max insertionid (attribute in trans measure table). How would you guys suggest I go about this?
    I'm new to mdx and I'm converting a whole sql statement to a measure not to include it as a named query for performance concerns!
    If needed this is the sql query im converting:
    SELECT TOP (1) InsertionDT
    FROM dbo.TransTasksFFMS_GVT AS TSI
    WHERE (TaskCode = T.TaskCode) AND (TaskStatus = 1) AND (TaskSubStatus = 1)
    ORDER BY InsertionDT) AS RegistrationTimeWithoutConversion
    Another way to think of this is how to apply a certain measure only on certain values and not all values in the browser.

    Hi Junior,
    According to your description, you want to get the max value by using MDX query, right? Since no know your cube detail information, we cannot convert this T-SQL to MDX query. Here is a sample MDX query for your reference. The query below returns the Sale
    Amount measure and the MaxValue calculated member.  The MaxValue calculated member takes the maximum value for members of the Fiscal Year level in the Fiscal hierarchy of the Date dimension.
    WITH
    MEMBER [Measures].[MaxValue] AS
    MAX([Date].[Fiscal].[Fiscal Year].Members, [Measures].[Sales Amount])
    SELECT
    {[Measures].[Sales Amount],[Measures].[MaxValue]} ON COLUMNS,
    {[Date].[Fiscal].[Fiscal Year].Members} ON ROWS
    FROM
    [Adventure Works]
    Reference:Max (MDX)
    Regards,
    Charlie Liao
    TechNet Community Support

  • Combine two resultset sidebyside in coulmn using mdx

    hi i am new to mdx,
    i want to combine two select statement resultset (side by side like union) using mdx query,please any body help me to solve this query
    first query:
     SELECT
    { [Last Year] }
    ON COLUMNS,
     { {[Location].[Location].&[7], [Location].[Location].&[12], [Location].[Location].&[11],
    [Location].[Location].&[19], [Location].[Location].&[17], [Location].[Location].&[16],
    [Location].[Location].&[9], [Location].[Location].&[18] },{[Location].[Location].[All]}}
    ON ROWS
    FROM [Cube1]
    WHERE ( [Measures].[Labour %] )
    here [Last Year] is a calculated set
    {STRTOMEMBER("[Date].[Month].&["+ cstr(year(now())-2) +"-11-01T00:00:00]"):
            (STRTOMEMBER("[Date].[Month].&["+ cstr(year(now())-1) +"-10-01T00:00:00]"))}
    2nd query:
    WITH MEMBER [Measures].[Budget ] AS IIF(avg([Last Year],IIF(([Measures].[Budget]>0),[Measures].[Budget],null)),
                                            avg([Last Year],IIF(([Measures].[Budget]>0),[Measures].[Budget],null)),0.00),
    MEMBER [Measures].[YTD] AS IIF(avg([Last Year], IIF(([Measures].[Labour %]>0),[Measures].[Labour %],null))<>null,
                                  avg([Last Year], IIF(([Measures].[Labour %]>0),[Measures].[Labour %],null)),0.00),
    FORMAT_STRING = "Standard",
    BACK_COLOR = CASE WHEN [YTD] = 0  THEN /*White*/16777215 /*White*/  
    WHEN [YTD] <= [Measures].[Budget ] THEN 65408
         WHEN [YTD]<= [Measures].[Budget ] +5 THEN 65535
         WHEN [YTD]> [Measures].[Budget ] +5 THEN 255
    END,
    VISIBLE = 1
    SELECT
    {  [Measures].[YTD], [Measures].[Budget ] }
    ON COLUMNS,
    { { [Location].[Location].&[7], [Location].[Location].&[12], [Location].[Location].&[11], [Location].[Location].&[19], [Location].[Location].&[17], [Location].[Location].&[16], [Location].[Location].&[9], [Location].[Location].&[18]
    },{[Location].[Location].[All]} }
    ON ROWS
    FROM [Cube1]
    here   ==> [Measures].[YTD], [Measures].[Budget ] are calculated member
    i want result like in
    coulmns===> ytd,budget,nov,dec,jan,feb.,,,,,,,,,,out
    rows ====> are only locations and total(average of all locations)
    please guide me to get solution like mdx query

    Hi Vsp,
    According to your description, you want to create a calculated member to combine two members, and then set it as Default member, right?
    In SQL Server Analysis Services, we can use the script below to create a calculated members.
    create member currentcube.[Date].[Day of Week].[weekend]
    as
    {[Date].[Day of Week].&[6],[Date].[Day of Week].&[7]
    Every attribute in a dimension in Microsoft SQL Server Analysis Services has a default member, which you can specify by using the
    DefaultMember property for an attribute. This setting is used to evaluate expressions if an attribute is not included in a query. Please refer to the link below to see the detail information about specify a default member.
    http://technet.microsoft.com/en-us/library/ms174822(v=sql.105).aspx
    Regards,
    Charlie Liao
    TechNet Community Support

  • Need MDX query to find something like date diff and Date Range for last 10 days

    Hi ,
    I need two Query .First Query for below;
    I have below data in table like.
    Cat      StartDate    EndDate     
    A    2000-01-01     2000-01-15   
    B    2000-01-02     2000-01-30    
    C    2000-01-01     2000-01-31    
    D    2000-02-01     2000-02-28    
    A    2000-01-10     2000-01-31    
    I need if Startdate and Date completes whole one month then set status =1 else  0 using MDX query.
    like this ;
    Cat      StartDate    EndDate       Status
    A    2000-01-01     2000-01-15    1
    B    2000-01-02     2000-01-30    0
    C    2000-01-01     2000-01-31    1
    D    2000-02-01     2000-02-28    1
    A    2000-01-10     2000-01-31    1
    In second query I need last 10 days from current days like;
    Now = 8/20/2014
    output will be ;
    8/20/2014
    8/19/2014
    8/18/2014
    8/17/2014
    8/16/2014
    8/15/2014
    8/14/2014
    8/13/2014
    8/12/2014
    8/11/2014
    8/10/2014
    Please help me .
    Thanks

    Hi Prajapati,
    In your scenario, you can use Properties and Datediff function to achieve your requirement. Since not know the structure of your cube, we cannot give you the esact query.
     I have tested it on the AdventureWorks cube, the query below is for you reference.
    WITH MEMBER [Measures].[StartDate]
    AS
    [Employee].[Employee Department].CURRENTMEMBER.PROPERTIES('Start Date')
    MEMBER [Measures].[WorkYear]
    AS
    DATEDIFF('yyyy',[Measures].[StartDate],NOW())
    MEMBER [Measures].[Status]
    AS
    IIF(DATEDIFF('yyyy',[Measures].[StartDate],NOW())>10,1,0)
    SELECT {[Measures].[StartDate],[Measures].[WorkYear],[Measures].[Status]} ON 0,
    [Employee].[Employee Department].[Employee].MEMBERS ON 1
    FROM [Adventure Works]
    Results
    Reference
    http://msdn.microsoft.com/en-us/library/ms144821.aspx
    Regards,
    Charlie Liao
    TechNet Community Support

  • Missing field for MDX query for All Members

    Hello,
    I'm using MDX query with SSRS for report and I ran into this issue:
    Query 1:
    select non empty ([Product].[Category].allmembers*[Date].[Calendar].[Calendar Year].allmembers ) on 1,
    ([Measures].[Internet Sales Amount]) on 0
    from [Adventure Works]
    go
    Query 2
    select non empty ([Product].[Category].[All]*[Date].[Calendar].[Calendar Year].allmembers ) on 1,
    ([Measures].[Internet Sales Amount]) on 0
    from [Adventure Works]
    In case I run query 2 in SSDT (query designer), it doesn't return first column whereas if I run above two queries in SSMS, I get similar columns/fields.
    How it can be resolved in SSRS to return all columns for query 1 and 2.
    Thanks,
    P
    mark it as answer if it answered your question :)

    Hello,
    I'm using MDX query with SSRS for report and I ran into this issue:
    Query 1:
    select non empty ([Product].[Category].allmembers*[Date].[Calendar].[Calendar Year].allmembers ) on 1,
    ([Measures].[Internet Sales Amount]) on 0
    from [Adventure Works]
    go
    Query 2
    select non empty ([Product].[Category].[All]*[Date].[Calendar].[Calendar Year].allmembers ) on 1,
    ([Measures].[Internet Sales Amount]) on 0
    from [Adventure Works]
    In case I run query 2 in SSDT (query designer), it doesn't return first column whereas if I run above two queries in SSMS, I get similar columns/fields.
    How it can be resolved in SSRS to return all columns for query 1 and 2.
    Thanks,
    P

  • MDX query

    Hi,
    In my Date dimension table DateKey will be 1,2,3,4........
     DateKey 1= 22nd Jan,2010
     DateKey 2= 23rd Jan,2010
     DateKey 3= 24th Jan,2010.
    Now i want to get Today date(Ex.22jan2014) and LastYearSameDay date(Ex.23jan2014) by using mdx query.
    Can you please suggest me.
    Sudhan

    Hello,
    I think you should ask in the SQL Server Reporting Services, Power View forum.
    Karl
    When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer.
    My Blog: Unlock PowerShell
    My Book: Windows PowerShell 2.0 Bible
    My E-mail: -join ('6F6C646B61726C40686F746D61696C2E636F6D'-split'(?<=\G.{2})'|%{if($_){[char][int]"0x$_"}})

  • Sorting query in MDX query filter in PPS

    Hi,
    Iam new to the PPS world. Iam using MDX query filter and I need to create a filter field using the [BusinessLine].[Department] dimension. I need to sort the display value of Department in descending order in the filter and Iam using the following
    Order([BusinessLine].[Department],[BusinessLine].[Department],DESC) in the query window while creating the filter. But Iam getting 'No value found'! result.
    Please let me know Iam doing any mistake in this

    Hi Umair,
    Thanks for the reply
    The department here is Attribute and BusinessLine is dimension in my cube.For other requirement(the department has to be sorted based on the creation date attribute) purpose I have kept department as composite key with other attribute called CREATE_DATE
    with named column as department
    Order (
    [BuisnessLine].[Department].[DEPARTMENT],
    [BusinessLine].[CREATE_DATE].Properties("Name"),
    DESC
    Iam just replacing the above query as it is in the Enter MDX formul? page
    Is it correct.

  • Find current age from day in mdx query

    Hi,
    I need to find current age.In my cube i have dob attribute.
    so how can  i find current age from day using mdx query.
    Thanks,
    Indu
    indu

    Hi,
    when i ran above query, i am getting days.
    But i need current age in years.
    so i tried with below query, then i am getting value  like 8.99.how can i round off in mdx query?
    in sql i used Floor function for roundoff. in mdx which function should i use?
    With
    MEMBER [DOB] AS DATEDIFF('d',[Ship Date].[Date].CurrentMember.Name,Now())/365.25
    Select {[DOB]}
    on columns ,
    NON
    EMPTY {[Ship Date].[Date].[Date]}
    ON ROWS From [Adventure Works]
    indu

  • MDX query To get DateKey based on my Dimension table

    Hi,
    In my Date dimension table DateKey will be 1,2,3,4........
     DateKey 1= 22nd Jan,2010
     DateKey 2= 23rd Jan,2010
     DateKey 3= 24th Jan,2010.
    Now i want to get Today date(Ex.22jan2014) and LastYearSameDay date(Ex.23jan2014) by using mdx query.
    Can you please suggest me.
    Sudhan

    Hi Sudhan,
    According to your description, you want to get Today date and LastYearSameDay date by using mdx query. In this case, you can use Now() function and DateAdd function to get the result. Here is a sample query for your reference.
    WITH MEMBER Measures.Today AS vba!Now(), FORMAT_STRING="Short Date"
    MEMBER Measures.Yesterday AS Dateadd("d",-1,Measures.Today), FORMAT_STRING="Short Date"
    SELECT {Measures.Today,Measures.Yesterday} on 0
    FROM
    [Adventure Works]
    Result:
    Regards,
    Charlie Liao
    TechNet Community Support

Maybe you are looking for

  • Code coloring error in HTML5 templates

    Is it just me? In both HTML5 templates (two or three column), that one can select after select 'New' from the 'File' menu the code is all grayed out after the browser conditional: <!DOCTYPE HTML> <html> <head> <meta http-equiv="Content-Type" content=

  • Cookie stickiness configuration issue with Cisco ACE

                       Hi, We have configured a ACE (in standby mode) with ip netmask stickiness and wanted to configure cookie stickiness for a remedy server placed behind the ace. BMC has said that they use JSESSIONID field on the remedy application an

  • Old pictures and vhs tapes

    I have many old pictures that I would like to put on my computer to make a CD/DVD of. How can I do this? Also, how do I put old VHS tapes onto my computer or just onto a DVD? And how much would those things cost?

  • 1st generation MacBook not pairing/connecting with Apple Wireless Keyboard

    I just purchased an Apple Wireless Keyboard to use with my iPhone and my 1st generation MacBook. I managed to pair/connect my keyboard with iPhone on my first try. So far, however, I have not been able to pair or connect my keyboard with my MacBook.

  • GUID format needed to make bootable HD for intel iMac?

    I have one brand new 1TB hard drive, and an old 250GB. Both Lacies. I have a newish intel iMac and an old G4 tower. Am I right in thinking that, in order to make a bootable clone for the iMac, I need to format the 1TB as GUID? Will I then not be able