cancel
Showing results for 
Search instead for 
Did you mean: 

Date Conversion

Former Member
0 Kudos

Hi,

I have date stored as 15-09-2011 in DB Connect source system.

When i load to to datasource which is havinf CHAR 10 field the result is stored as 14.09.2011. - goes...

Now in standard DSO i have DATS field with length 8.

I want this data in YYYYMMDD format.

I utried using all consersion routines did not work.

I used below formula in transfer rule types

DATECONV( /BIC/Z_11, 'DDMMYYYY', '-' ) and also DATECONV( /BIC/Z_11, 'DDMMYYYY', '.' ) and DATECONV( /BIC/Z_11, 'DMY', '-' )

all possible ways did not work.

I also used belwo routine in transfer rule type:

Data : month(2) type c,
date(2) type c,
year(4) type c.


date = SOURCE_FIELDS(2).
month = SOURCE_FIELDS+3(2).
year = SOURCE_FIELDS+6(4).

Concatenate year MONTH Date into RESULT .

Not working.

Please suggest what to do now.

Regards

Zabi

Accepted Solutions (0)

Answers (3)

Answers (3)

former_member188080
Active Contributor
0 Kudos

Hi,

Please see if you can achieve your results through

start -


control panel---regional and language options--regional options

here you can see various date and time option.See making any changes helps you.

Thanks and regards

Kiran

Former Member
0 Kudos

Hi,

You can try to put,

date = SOURCE_FIELDS+0(2).

It might not be causing the problem but you can still check this out. The best way to check is simply debug your code and see what values you are getting populated in each of the fields.

Regards,

Durgesh.

Former Member
0 Kudos

Hi Zabi,

Your routine looks good, it should give you the desired result.

I will suggest you debug the routine once, it will give you a fair idea what exactly are the values present in the declared variables.

Hope this helps.

Regards,

RahulM

Edited by: RahulM on Sep 15, 2011 3:05 PM

Former Member
0 Kudos

Hi,

I tried with above changes but error.

I am trying to set breakpoint in transfer routine but it says breakpoints can be set in active unchanged mode.

I dont knwo what to do.

Please suggest.

Regards

Syed

Former Member
0 Kudos

Hi Syed,

Put the statement BREAK-POINT where you intend to put the session breakpoint and then debug.

Regards,

RahulM