dbTalk Databases Forums  

using DateDiff in Analysis 2005 BIDS

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss using DateDiff in Analysis 2005 BIDS in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Karthik Rao
 
Posts: n/a

Default using DateDiff in Analysis 2005 BIDS - 12-28-2005 , 01:10 AM






HI:
i need to weight inventory by days to calculate cost of carry. I tried
to use a VBA function
Datediff(day, date1, date2). This is in a claculated meber in BIDS.

Where date1 is the second inflow of a particular product, and date2 is
the first inflow.

I tried all values for interval like d,dd, day, even the enum values 3
and 4. But I keep getting error argument interval expected etc. If I do
not quote strings, I get a dimension not found error.

What am I doing wrong?
Thanks a lot


Reply With Quote
  #2  
Old   
Karthik Rao
 
Posts: n/a

Default Re: using DateDiff in Analysis 2005 BIDS - 12-28-2005 , 12:07 PM






I used DateDiff("D", Date1, Date2) and it seems to work. I even tried
using the EnumValues, but got the Interval error.

Is this function case sensitive? Are there any local issues here? Why
isnt the enum Value working?

Thanks


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.