SQL using Python – fetch speed issue
I’m attempting to run a SQL query to select two columns from a table. The issue comes when I use the cursor.fetchall()
method, which takes 0.2 seconds to return the columns when in other similar cases it takes <0.01 seconds. The returned list is only 1-5 tuples long, so isn’t an extreme amount of data.
Choosing a DBMS and supporting Python libraries for an introductory course
I am supposed to give an introductory course to SQL and databases next semester. The students are supposed to know basics in Python programming already (we are using Python 3.8 or later) and had some exposition to networking. I like the students to use local DBs that they create on their devices as well as sometimes work with a remote DB on a server. The computer room comes with Windows PCs, but students can in principle bring their own devices, and it would therefore be nice if Apple and Linux would be supported without to much hassle. It would also be nice if the setup would be mostly open source (no fees and stuff).