Search code examples
azureazure-iot-hubazure-stream-analytics

How to get the raw JSON coming from an IoT Hub?


I'm using Streaming Analytics to retrieve JSON messages being placed on an IoTHub. I need to be able to retrieve, and store, in a SQL Server table, the raw JSON string. I can't seem to find a way to do this. Is it possible?


Solution

  • No, unless you wrap the json as string in another json object that is send to the IoT Hub.

    Otherwise the solution would be to try whether you can stringify / construct the json object using a Javascript function and then store it in the database.