Python Check If Any Substring In Sql