Skip to content

Tag: python

Importing .bak MySQL database with Python using pymssql

The title is pretty self explanotory. I’ve tried the following code : But I get the following error : No module named ‘_mssql’. I have the version 2.2.2 of pymssql and I use Python 3.9. I’m just trying to write and read from this database, and I only have the .bak file. I’m quite…

How to display and link two sql tables?

I’m trying to display genres from a “Genre” Table in SQL to my main table I found a way to do it with one item but I cannot find a way to do it with multiple genres I got an error from this and I don’t know how to fix it. My SQL database: Answer Do a LEFT JOIN for

constructing a message format from the fetchall result in python

*New to Programming Question: I need to use the below “Data” (two rows as arrays) queried from sql and use it to create the message structure below. data from sql using fetchall() ##expected message structure I tried to create below method to iterate over the rows and then input the values, this i…