If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

_make_timestamp mistery

Started by clingst, 01 Aug 2015 07:10:20 AM

Previous topic - Next topic

clingst

good day all..

i understand that the usage of _make_timestamp is computing a date with given year,month,day in integer format

However, i noticed that this function allows the "next month" display if the an extra DAY value is given for a particular month..

eg:

_make_timestamp (2015,1,31) yield 2015-01-31 : OK
_make_timestamp (2015,1,32) yield 2015-02-01 : The extra day is carried to the sequence month
_make_timestamp (2015,1,33) yield 2015-02-02 : The extra day is carried to the sequence month
_make_timestamp (2015,1,365) yield 2015-04-19 : I am expecting 2015-12-31. Any idea why it is so?

Understanding this would help me alot becoz I am getting a Julian date which is in Integer data type from my source
eg: 2015095 represent 2015-04-01

I need a date data type to build my cube.
Appreciate for advice!

bus_pass_man


Lynn

Quote from: clingst on 01 Aug 2015 07:10:20 AM
good day all..

i understand that the usage of _make_timestamp is computing a date with given year,month,day in integer format

However, i noticed that this function allows the "next month" display if the an extra DAY value is given for a particular month..

eg:

_make_timestamp (2015,1,31) yield 2015-01-31 : OK
_make_timestamp (2015,1,32) yield 2015-02-01 : The extra day is carried to the sequence month
_make_timestamp (2015,1,33) yield 2015-02-02 : The extra day is carried to the sequence month
_make_timestamp (2015,1,365) yield 2015-04-19 : I am expecting 2015-12-31. Any idea why it is so?

Understanding this would help me alot becoz I am getting a Julian date which is in Integer data type from my source
eg: 2015095 represent 2015-04-01

I need a date data type to build my cube.
Appreciate for advice!

I'm not sure what that integer value is, but it is not a julian date. The correct julian value for 2015-04-01 is 2457114. Since April 1 is the 91st day of 2015 that doesn't quite fit with the 201595 figure you've posted.

If you can explain what that number is then perhaps you can get some help converting it to a date.