I have a basic Python interface to a database, where what would be the "connection" class does the querying and retrieveing as well.
I was wondering whether it would make sense to write a dummy cursor()
function inside that class as:
def cursor(self):
return self
and then just implement fetch()
et al. in the same class.
If it makes a difference, the goal is to connect the database with SQLAlchemy.