Raspberry Pi and SQL Server

raspberry Pi Zero Board from my book on Visual Basic

Raspberry Pi and SQL Server

using Python/Tkinter and Raspbian and a video using Microsoft SQL Server.


The Raspberry Pi show above is an amazing little computer.  When I first bought mine, I wondered what it really could do.   I decided to load the Raspbian OS that is supposedly the main Operating System used on the Pi, and just see what this little guy could do.  SQL Server was not even anything I had thought about using when I began this journey.

I found quickly to my surprise there were a lot of neat things about the Raspberry Pi.  It came with Python, Libre Office, Scratch, Browser, many Admin tools, and just about anything you would need to make it your own personal computer.  I attached it to a remote hard disk and then to printers and networks.  I experimented with VNC and it worked flawlessly, so I could do things from my PC with a bigger screen and did not need a keyboard or monitor for the Pi at all.

Most of you know all that already though.  I decided to put a “toe in the water” with Python, although Linux never interested me nor languages without a GUI interface.  I found out that Tkinter did provide a GUI, and it could do some interesting things.

This intrigued me to try and see if the Raspberry Pi and SQL Server would work from one of my of my websites.  Now this turned out to be cool although (JSON or SOAP web Services are preferred), and turned out to be much more robust that I had imagined.  There are a bunch of setups and sudo commands to download all the libraries that the Pi and Python need.  Unfortunately, there is documentation that is incorrect that contains typo’s and incorrect information.  I am not going to fix that here.  Some day when I have time I will go back and write a solid document about it, but for now I want to just show you it is possible and the speed that is has.

In the Video below,  I will show you the speed and actual interface I created.  It shows MS SQL Server can be accessed and it can be extremely fast.  This is true with Python and Visual Basic.

Do note that this is accessing an 8,000-10,000 row table, and there are no indexes.  Whatever is put in the top textbox is put in the where clause of the SQL select statement.  It is updated in the label below the results.  I am limiting the return to 100 or so rows for testing.

Thanks for viewing.

This video was just to show that this can be done, and that it works well.

If you are more of a MS Windows Programmer check out my new book on the Raspberry Pi and Visual Basic, Programming Windows 10 IoT.  There is a similar example there.

Take a look at the book on Kindle or Amazon, if you are interested in programming the Raspberry Pi using Visual Basic and VS 2017(Visual Studio 2017).

This is the book purchase area.
https://www.amazon.com/dp/0692071881/ref=sr_1_1?s=books&ie=UTF8&qid=1520546916&sr=8-1&keywords=visual+basic+raspberry+pi

Kindle Purchase area (some graphics are not good on Kindle devices)
https://www.amazon.com/Raspberry-Pi-Visual-Basic-Programming-ebook/dp/B07B5W3P8V/ref=sr_1_2?s=books&ie=UTF8&qid=1520546916&sr=8-2&keywords=visual+basic+raspberry+pi

Enjoy the Video on Raspberry Pi and SQL Server using Python.

Be the first to comment

Leave a Reply