0

I have this :

Insertion des données dans table some_table.0 - SOME_AUTO_GENERATED_DB_KEY Integer : There was a data type error: the data type of java.lang.Boolean object [true] does not correspond to value meta [Integer]

What boolean??? Where do you see a boolean? I have added a trace writing to the step just before this failing inserting step, and I see a perfectly fine integer as value of SOME_AUTO_GENERATED_DB_KEY .

How can this be possible? I am very new to Kettle, if you have any idea or tips it would be awesome.

Here a screenshot of the transformation :

Transformation

Julien
  • 2,616
  • 1
  • 30
  • 43

1 Answers1

2

Just before the failed insert, you have a filter that splits the stream. On one half of the stream, it looks like you have an Add Constant step. If I'm reading this right, then the two inputs to the Insert step don't have the same fields in the same order. A few steps earlier, there is a similar splitting of the paths that goes off to the right, which could have the same effect.

Whenever you remerge streams like this without being very careful, strange errors like this can pop up. Pentaho usually tries to warn you when you create the hop to remerge the streams, but there are ways to miss that warning.

Suggestion: For each time the stream remerges, right-click on each of the two previous steps, and have it show you the output fields. Compare the two lists side-by-side to verify they are the same. If not, then you will have to add or remove fields as appropriate to make them the same on both sides.

Ken Clubok
  • 1,238
  • 6
  • 11
  • Finally I have resolved the problem, then I understood your answer and I realized that you were right (despite the few information I gave, thanks). Actually there was an error message when I tried to link one of the branch to the "aggregation" point. Something like "number of columns is not the same, etc...". First I think it is strange that pentaho is not able to find out by itself the order of the column, after all they have names and it would be pretty easy! Second, in this case the execution should fail sooner because of the incompatible column number, not because of a weird type error. – Julien Feb 29 '16 at 09:34