0
votes

I use Stream Analytic to save the EventHub data into an SQL DataBase. Even though I can see that I have both input and output requests, when I write a query to see the data from the output table I can see just 200 empty rows!! So I send data to this table, but are just NULL values

I think the problem may bethe query between input and output because my output table is empty :(. This is how I wrote it:

SELECT id,sensor,val FROM EventHubInput

Could there be another problem? I have to mention that my EventHub is the link between a Meshlium and Azure.This is why I think my problem can be also from the frame I send from Meshlium.

I really don't know what to do. HELP ?!

2

2 Answers

1
votes

You haven't specified any output.

SELECT id,sensor,val 
OUTPUT YourSQLOutput
FROM EventHubInput
1
votes

Stream Analytics queries' default output is output.

So if your SQL DB alias is SQLDbOutput, it won't work. You should specify it yourself:

SELECT id,sensor,val
INTO SQLDbOutput
FROM EventHubInput

The editor in Azure should tell you the names of your inputs and outputs on the left.


Also make sure your events in Event Hub contain those properties (id, sensor, val), and that the SQL DB contains columns with the same names.