Your new topic does not fit any of the above??? Check first. Then post here. Thanks.

Moderator: igrr

User avatar
By trackerj
#35728 Depends a lot on how you can access your SQL Server.
If you have exposed SQL Server database as a web service, SOAP might be one of the answers you are looking for.
User avatar
By grantnlee
#35813 I am working on something similar. I have made some progress, but do not have my project where I want it yet...

To get started, I first captured my sensor readings and am posting the readings to ThingSpeak. You might try this first, just to make sure your ESP is doing what you want. ThingSpeak uses HTTP calls (i.e. simply like reading a web page), and you simply include the data readings as fields at the end of your HTTP call. ThingSpeak automatically charts the data points and you get some rapid gratification seeing that your data collection is working. You can even embed their charts in your own website pages potentially getting you closer to what you might be seeking... There are a lot of examples and it is really straight forward, and free to use. But there do seem to be some limitations keeping me from doing everything I want.

My next step down this path is to host my own database for sensor data as well as front end that database with a website for my use case. My current approach is to use the Ruby on Rails framework. This take a little learning if you are new to Ruby and web development concepts like MVC. But Rails excels at automating the process of building interactive API 'endpoints' around a database (such as Postgres or MySQL.) These endpoints would work similarly to the ThingSpeak hosting service HTTP calls mentioned above. So for getting serious about standing up a database driven website, and unless you are strong in some other set of tools, then Rails may be a good approach for you. And there are a tremendous amount of Rails tutorials out there to get started. That said, I have not found much Rails activity in either the ESP or Arduino forums around using Rails specifically with embedded controller data.

Good luck.
- Jay
User avatar
By Alexandre Pinheiro
#41613 Yes, you can and It's relatively easy.

I don't use LUA. I'm using the Arduino IDE to program the ESP. There's a SQL library ready to use, but I'm facing some stability problems. After some time (max. 15 minutes), the ESP hangs forcing you to reset it. Right now, I'm trying to solve this problem. It seems to be related to SQL, but I'm still testing. I'm can't tell for sure if it's related to SQL library or some error in my sketch.