While the way to get data from a SQL data table to a python program isn't great to begin with, I hate that entering that data into a pandas data frame removes the column names. This function retrieves the column names from the SQL data able and assigns them to the pandas data frame before returning it out side the function.
#sql #python #pandas #dataframe #mysql #datatable #datalookup