1

I have a database table called shop. Every shop has a string title.

I'm now trying to get all the shops that has a title that does not start with an English alphabet character.

So now I'm doing something like:

shops = db.query(Shop)\
        .filter(Shop.title.like('SOME_EXPRESSION'))\
        .all()

May I know what to choose for SOME_EXPRESSION please? Do I need a regular expression here? Or some other expression?

From what I know, if I put A% there, it is getting all shops with title that starts with A.

Mark Hildreth
  • 42,023
  • 11
  • 120
  • 109
pianoguy
  • 11
  • 2
  • [Here](http://stackoverflow.com/questions/11196538/return-rows-where-first-character-is-non-alpha) is a question with answers that show ways to do this in SQL. Once you know that, you can convert the SQL to SQLAlchemy. – Mark Hildreth Oct 27 '13 at 16:29

0 Answers0