Reading data into pandas from a sql server database is very important. If you plan on working for a company you HAVE TO know how to use Pandas and SQL. This video will show you how.
What is Pandas? A Python data analysis library
Most big companies either use Microsoft or Oracle for their RDBMS (relational database management system). There are others like mysql but if you learn these two, you should be covered in most cases. This video will concentrate on getting data out of a Microsoft database.
We first connect to sql server and then open the database called BizIntel. This is where you will find a table called "data". Note this is all made up data created for the purposes of this tutorial.
The table contains three columns: Date, Symbol, and Volume
This table simulates stock prices and their volume on a specific date.
We then turn to the Jupyter notebook and start to import SQL specific Python libraries like PyODBC. We then proceed with explaining code on how to connect to your local mssql (microsoft sql server) instance via Pandas and PyODBC. This is how we go to pandas from sql.
We finally generate the sql statement for pandas and read in the data. This is a very basic example and we did not have to supply the odbc connection any passwords. We also did not have to worry about changing any of the datatypes of our dataframe as they were imported into pandas without any issues.
🔥 Free Pandas Course: https://hedaro.gumroad.com/l/tqqfq
On this page of the site you can watch the video online Pandas SQL - How to read data from a microsoft sql database with a duration of hours minute second in good quality, which was uploaded by the user Learn Pandas 24 November 2014, share the link with friends and acquaintances, this video has already been watched 49,512 times on youtube and it was liked by 365 viewers. Enjoy your viewing!