Page 1 of 1

How to convert date in Datastage internal format in Parallel

Posted: Fri Feb 13, 2015 7:42 am
by ramakrishna459
Hi All,

In server jobs if i give @DATE as derivation its converting to Datastage internal format.

As below:

2015-02-13-->17211

How to acheive the same in parallel jobs.

Thanks
Ramakrishna

Posted: Fri Feb 13, 2015 8:06 am
by chulett
Why don't you let us know what problem you are trying to solve, why you think you need this. Then perhaps we can provide a more proper Parallel solution.

Posted: Fri Feb 13, 2015 2:29 pm
by qt_ky
I'm guessing this is an academic question but would be curious if there were a real world reason behind it.

Parallel jobs are unaware of Server jobs' internal date format.

A parallel concept in Parallel jobs can be found in the JulianDayFromDate() function. It returns an integer based on the input date, however it's a different integer than the one chosen for Server jobs (Server jobs' zero date chosen by Mr. Pick?).

One could add or subtract a value to convert Sequence/Server jobs' internal day number back and forth with a Julian day number.

:wink:

Posted: Wed Apr 15, 2015 11:50 pm
by ramakrishna459
As a part of ETL migration we thought of converting server job date format to be generated by parallel job.But we couldnt acomplish by parallel job hence we used the same.

Posted: Thu Apr 16, 2015 1:43 am
by ray.wurlod
Parallel jobs automatically use their own internal format for dates (indeed for most other data types too). See chapter 2 of Parallel Job Developer's Guide for details.

The parallel job internal format is not the same as the server job internal format, but why would you need the latter in a parallel job? (They are both offsets from a particular "day zero" but, as Craig suggests, a different "day zero".)