cancel
Showing results for 
Search instead for 
Did you mean: 

Null values getting populated in the Target permanent table

santossh
Active Participant
0 Kudos

Hello Team,

I have a scenario where I observed an unusual behavior of Job.

Scenario :

I have a DF in which we have 1 ABAP DF to extract the data from CRM.

Sometimes, when I execute this job null values get populated in all the fields and all the rows of the table and

re-executing it I receive the complete set of data.

This behavior of the job is uncertain in nature.

Has anyone faced such kind of issue earlier, if yes please provide your valuable suggestions.

I have attached the screenshot for reference.

Regards,

Santosh g.

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member187605
Active Contributor
0 Kudos

Are you sure values are null? Please double-check with your database client. It might just be a hiccup in the DS Designer - database interface.

santossh
Active Participant
0 Kudos

Thanks Dirk for prompt reply.

Yes, I checked in database as well and there as well I could find the null values.

former_member187605
Active Contributor
0 Kudos

Can you make (at least) one of the columns mandatory? Just wondering what type of error message you'll get.

santossh
Active Participant
0 Kudos

Sorry Dirk,

But I couldn't get about the mandatory bit. Could you please elaborate in detail.

former_member187605
Active Contributor
0 Kudos

You should change your target table definition and make at least one of its columns NOT NULL.

santossh
Active Participant
0 Kudos

Hi Dirk,

One strange observation.

I scheduled the job and it executed without any issue.

After clicking the view data option in the target table I could view the data but, when I refreshed the table data after 5min the table was full of null records - even in the database.

Later, I did the table re-import and executed the job but, no luck.

Any clue why this happens.

Regards,

Santosh

former_member187605
Active Contributor
0 Kudos

You mean data is loaded correctly in the target and then all of a sudden it disappears? No clue what can be the reason, but I don't think you can blame DS for that.

santossh
Active Participant
0 Kudos

Hi Dirk,

Actually this table was used as target table in other DF and that's where the values were getting converted to null .

Now, in the next DF(let's call it as DF2 ) :

1.  Here, we are actually converting decimal to date and then populating the values into the target table. The flow is :


ABAP DF -> QT1(mapping) -> QT2(conversion decimal to date) -> TT(Tgt Tbl)

When DF2 gets executed completely it loads null values in the target table .


Here, I even removed the TT and replaced it with the other table and still the results were same.


2. When I add a new query xform between the Target table and the conversion query xform, I'm able to get the values . The new flow is:

ABAP DF -> QT1(mapping) -> QT2(conversion decimal to date) -> QT3(mapping) -> TT(Tgt Tbl)

Is there anything going wrong with the conversion and loading of the data at the same time or is there anything getting disturbed in the data flow. Please find the attached file of conversion QT.

Thanks is advance,

Santosh

former_member187605
Active Contributor
0 Kudos

The first parameter of to_date must be of type varchar. In order to guarantee correct results, explicitly convert your decimal value to character first (make sure to check the generated value, it may contain leading blank) and the apply the to_date with the correct format.

santossh
Active Participant
0 Kudos

HI Dirk,


Below are some new findings:


In regular execution mode:

I tried converting decimal to varchar first and then to date. It didn't work(i.e. I got null values in the table).

But,In debug mode:

I'm able to see the values in the table at the end.

Former Member
0 Kudos

Does your job create any warnings? When I use to_date and it fails to parse, I get a null and a warning in the logs. I'd think you'd see a warning too if the parse fails.

santossh
Active Participant
0 Kudos

No Robin - No warnings