Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I 'm using three t_map to lookup from three different postgres tables and than insert into one postgres table .
But I'm getting the error below :
Exception in component tMap_3 (Load_DimSong)
java.lang.ArrayIndexOutOfBoundsException: 1
at decisionalproject.load_dimsong_0_1.Load_DimSong.tDBInput_3Process(Load_DimSong.java:3293)
at decisionalproject.load_dimsong_0_1.Load_DimSong.runJobInTOS(Load_DimSong.java:6365)
at decisionalproject.load_dimsong_0_1.Load_DimSong.main(Load_DimSong.java:6214) .
DB Version : v9.X
This is my job Load_DimSong.
Thank you .
Is lookup_release_dates_album.date_release allways populated?
I suggest you to transform the expression like this in case of:
lookup_release_dates_album.date_release != null ? lookup_release_dates_album.date_release.split("-")[1] : null
You may also refer to this link for a technic to avoid multiple calls to the String.split() method
So, what in tMap_3 ?
this is what in tmap3 :
The expressions for local variables are not visible.
Do we have to guess them?
I'm sorry .
my date_release is in this format yyyy-mm-jj
and I want to extract month , year and month+year from this date .
here are my expressions :
lookup_release_dates_album.date_release.split("-")[0] for variable dateYear
lookup_release_dates_album.date_release.split("-")[1] for variable dateMonth
lookup_release_dates_album.date_release.split("-")[0] +lookup_release_dates_album.date_release.split("-")[1] for variable datemonthYear.
Is lookup_release_dates_album.date_release allways populated?
I suggest you to transform the expression like this in case of:
lookup_release_dates_album.date_release != null ? lookup_release_dates_album.date_release.split("-")[1] : null
You may also refer to this link for a technic to avoid multiple calls to the String.split() method
Is lookup_release_dates_album.date_release allways populated?
I suggest you to transform the expression like this in case of:
lookup_release_dates_album.date_release != null ? lookup_release_dates_album.date_release.split("-")[1] : null
You may also refer to this link for a technic to avoid multiple calls to the String.split() method
Thank you so much !
I also added a condition song.date_release.length()>4 when I want to extract the month because sometimes the date comes with this format YYYY so my condition becomes :
(song.date_release!=null &&
song.date_release.length()>4 )?
song.date_release.split("-")[1]:null
Thank you again ! you helped me a lot .
I 'll try to change my splitted strings in the same way in the link u provided me with .
Thank's to mark your cas as solved.