I'm trying to select all rows in a sql table where the first four characters of a text column match a certain string. (The backend database is a sqlite instance with limited column types, so bear with me)
The code I've written for the select is this:
rows = SECtable.query.filter(str(SECtable.date)[:4] == str(matchingString)).all()
What am I doing wrong here? The query never matches any rows
query = SECtable.query.filter(...); print query.