4

I am taking JSON information from our online API and producing it in a table with DI. I have 4 fields url, deviceId, displacement & timestamp. These are all recorded as Strings but I want them to be Int values, bar the url.

In the Generate Rows section I tried changing each parameter to an Int but the results would not show up but if I left them as Strings, it will post the results.

Any help on how I could change the data from type String to Int and still have my data reported?

Dan
  • 2,020
  • 5
  • 32
  • 55

1 Answers1

13

Take Select/Rename values Step, and change the data-type in meta-data section.

Helping Hand..
  • 2,430
  • 4
  • 32
  • 52
  • 1
    I'm going to use this as well. What happens if there's a string accidentally in one of the rows? How do you default if it's not a number? – arcee123 May 17 '15 at 22:42
  • @arcee123 You can use the step *script* or call any class of java and validate from there – kelgwiin Jun 14 '16 at 11:09