RE: Current Time

Tech-Archive recommends: Fix windows errors by optimizing your registry




Thanks from me too. Works well, and it has got the flexibility I neede.


"HWUK" wrote:

> Try the following
>
> StrToMember("[Time].[Month].[" + Format(Now(), "mmmm ") + "]") and click ok.
>
> Now I know not all time dimensions are built the same way, in fact at one
> place I had to use the following - StrToMember("[Month].[Year].&[" +
> Format(Now(), "yyyy") + "].&["+ Format(Now(), "mmm") + "]")
>
> So for October 2004 the resulting MDX value looked like this -
>
> StrToMember("[Time].[Month].[" + Format(Now(), "mmmm ") + "]") =
> [Time].[Month].[October]
>
> StrToMember("[Month].[Year].&[" + Format(Now(), "yyyy") + "].&["+
> Format(Now(), "mmm") + "]") = [Month].[Year].&[2004].&[10]
>
> If the MDX doesn’t match your dimension it shouldn’t take long to figure the
> syntax.
>
> Hope this helps.
>
> Howard.
>
> Related forum
> -http://www.sqlservercentral.com/forums/shwmessage.aspx?forumid=17&messageid=139979
>
>
>
> "Miguel Salles" wrote:
>
> > Almost there!
> >
> > My cube is populated with future data (like something that we will sell
> > tomorrow) so the default member is now on september 2005 (last registered
> > sale)!!! This is why I wanted to use a member property on this matter, can
> > you help me?
> >
> > Thanks a lot
> >
> >
> > "HWUK" wrote:
> >
> > > Try this code as the default member in the time dim.
> > >
> > > Tail(Filter([Time].[Month].Members, NOT
> > > IsEmpty(Time.CurrentMember)),1).Item(0)
> > >
> > > Is this the kind of thing your looking for?
> > >
> > > "Miguel Salles" wrote:
> > >
> > > > Hi,
> > > >
> > > > I have a cube with my sales data. I'd like user to have the posibility to
> > > > use a "Today Sales", a "This Week Sales". How can I do this?
> > > > I thought of somehow using a dimension member property but I don't know how.
> > > > My source for the time dimension is a relational table that has 3 extra
> > > > columns name Current Date, Current Week and Current Month all of them are
> > > > datetime columns populated on the specific rows Like the CurretDate field is
> > > > always populated on a single record that shows wich day is today and so on.
> > > > Can I use this?
> > > >
> > > > Thanks
> > > >
.



Relevant Pages

  • RE: Current Time
    ... Now I know not all time dimensions are built the same way, ... If the MDX doesn’t match your dimension it shouldn’t take long to figure the ... This is why I wanted to use a member property on this matter, ...
    (microsoft.public.sqlserver.olap)
  • Re: Dynamic Default member ?
    ... Other than via a custom function, which has drawbacks, there's no way to ... and then create a member property based on ... > MDX Expression below, instead of relying on Nowfunction, what if I ... > to refer to the value of CurrPeriod in AppPara table ?? ...
    (microsoft.public.sqlserver.olap)
  • MDX
    ... I'd like to present member property in one column. ... My MDX ... NON EMPTY.members ... DIMENSION PROPERTIES.Name ON ROWS ...
    (microsoft.public.sqlserver.olap)
  • Re: Formula error- Property Name is not valid <Member key>"
    ... One dimension cannot be located on more than one axis at the same time. ... In your MDX, is from Measures which is already on Column axis. ... > I am new to MDX I am trying to access the member property of a cube. ...
    (microsoft.public.sqlserver.olap)
  • Joining Two Time Dimensions into one
    ... but i'm trying to Join Two Time dimensions from ... different cubes together in to a single Time Dimension. ... Spoffords MDX Solutions book, but that doesnt seem to show me how to do what ...
    (microsoft.public.sqlserver.olap)