0

I'll go straight to the point. I have a table input step, which reads records with a query that includes a where clause, as follows:

SELECT * id, name, surname, creation_date
FROM users
WHERE creation_date > ?

If a put a literal (i.e. '2017-04-02T00:00:00.000Z') in palce of the question mark, this step reads all new values, which could be thousands, in millis. If I use the field substitution and use the incoming value, it takes minutes.

Do you know why this could be happening? Do you know how to solve the issue?

Thank you very much for your time.

vantesllar
  • 469
  • 4
  • 13

1 Answers1

0

I found a workaround, not a solution for this particular issue, but it works: instead getting the value from the previous step and use field substitution (? in the query), I read the value in a previous transformation in the job, store it in the variables space, and read it from there using variable substitution ('${variable_name}' in the query), it works just as fast as if the value were hardcoded.

vantesllar
  • 469
  • 4
  • 13