skip to Main Content

Hello i am using the azure maps Geocoding API to extract lat lon information from address from flat files loaded into a datalake – i have been getting a type mismatch error when i try to use the function ‘toDecimal(body.results1.position.lon)’ in the derived column ( data flow task in ADF)
enter image description here

The error says "No field named results in the hierarchial structure. Thank you for your help

2

Answers


  1. When you don’t import the schema of the body in the external call transformation, you will get this kind of errors.

    Before importing schema:

    enter image description here

    To resolve it, delete the next transformations after the externalCall and first import the schema of the body in the externalCall transformation.

    enter image description here

    The schema will be generated dynamically in the Type of the body. Now, create the columns in the derived column and you can see the error got resolved and it will give the desired result.

    enter image description here

    Login or Signup to reply.
  2. It looks like you are trying to get the coordinates of the second result, not the first (arrays are zero index). In that case, it’s possible that there isn’t a second result (especially if you are doing street addresses), and thus toDecimal is getting null or undefined as an input.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search