cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
agent96 New Member
New Member

How to fix errors caused by inconsistent schema

I am kind of new to Azure Stream Analytics and all related services like power bi, but recently I've been trying to work on an IoT project. I had a number of sensors already pre-configured in addition, my IoT Hub setup as well. So what I'm trying to do is ingest sensor data via my IoT hub and push it to power bi for live streaming and visualization. However, whenever I start my ASA job, with two sensors connected (DHT11 & Water Sensor all via an ESP8266) that are sending data to the IoT hub in JSON format. The job fails after a while and gives this error

 

 

properties": {
        "Message Time": "2020-02-14 07:09:13Z",
        "Error": null,
        "Message": "First Occurred: 02/14/2020 07:09:13 | Resource Name: outputpowerbi | Message: Received a batch with inconsistent schemas. Please ensure that the schemas of output events are consistent and then restart the job. See 'https://aka.ms/asa-powerbi-schema-update' for more details on how to safely change the table's schema.",
        "Type": "DiagnosticMessage",
        "Correlation ID": "9317b7ab-dce3-4ea5-bc2f-6440fb53d0f0"
    },

 

 

I used Azure IoT explorer to extract/view the telemetry data being sent and here is how they both look like

 

Temperature & Humidity Sensor

 

 

{
  "body": {
    "deviceId": "temperatureSensor",
    "Temperature": 17.2,
    "Humidity": 164.8
  },
  "enqueuedTime": "2020-02-14T07:10:43.076Z",
  "properties": {},
  "systemProperties": {
    "iothub-connection-device-id": "temperatureSensor",
    "iothub-connection-auth-method": "{\"scope\":\"device\",\"type\":\"sas\",\"issuer\":\"iothub\",\"acceptingIpFilterRule\":null}",
    "iothub-connection-auth-generation-id": "637166446115566557",
    "iothub-enqueuedtime": 1581664243080,
    "iothub-message-source": "Telemetry",
    "x-opt-sequence-number": 26124,
    "x-opt-offset": "11293464",
    "x-opt-enqueued-time": 1581664243076
  }
}

 

 

 

Water Sensor

 

 

{
  "body": {
    "deviceId": "waterSensor",
    "Status": 0   
  },
  "enqueuedTime": "2020-02-14T04:39:13.205Z",
  "properties": {},
  "systemProperties": {
    "iothub-connection-device-id": "waterSensor",
    "iothub-connection-auth-method": "{\"scope\":\"device\",\"type\":\"sas\",\"issuer\":\"iothub\",\"acceptingIpFilterRule\":null}",
    "iothub-connection-auth-generation-id": "637166446422348866",
    "iothub-enqueuedtime": 1581655153204,
    "iothub-message-source": "Telemetry",
    "x-opt-sequence-number": 25163,
    "x-opt-offset": "10877712",
    "x-opt-enqueued-time": 1581655153205
  }
}

 

 

The line "Status:" 0 is just to show that there is no water/leakage detected. The overall idea is being able to connect multiple sensors via IoT hub and being able to see all sensor data being visualized on power bi without any conflict or issues.

Can anyone help  Cause I tried the reading what is on the link provided in the error but to no avail.


Thanks in advance.

Helpful resources

Announcements
Exclusive LIVE Community Event #3 – Ask Arun Anything

Exclusive LIVE Community Event #3 – Ask Arun Anything

Join us in the third Triple A event!

Meet the 2020 Season 1 Power BI Super Users!

Meet the 2020 Season 1 Power BI Super Users!

It’s the start of a new Super User season! Learn all about the new Super Users and brand-new tiered recognition system.

Super User Challenge: Can You Solve These?

Super User Challenge: Can You Solve These?

We're celebrating the start of the New Super User season with our first ever Super User 'Can You Solve These?' challenge.

Power BI Desktop Update - February 2020

Power BI Desktop Update - February 2020

We are super excited for our update this month, as we are releasing two of our top community requests!

Power Platform Online Conference

Power Platform Online Conference

Join us for the first ever Power Platform Online Conference!

Top Solution Authors
Top Kudoed Authors