diff --git a/orator/query/builder.py b/orator/query/builder.py index 60f59c10..76bd1208 100644 --- a/orator/query/builder.py +++ b/orator/query/builder.py @@ -688,6 +688,15 @@ def dynamic_where(*parameters): def _add_dynamic(self, segment, connector, parameters, index): self.where(segment, '=', parameters[index], connector) + def starts_with(self, column, search): + return self.where(column, 'LIKE', '{}%'.format(search)) + + def like(self, column, search): + return self.where(column, 'LIKE', '%{}%'.format(search)) + + def ends_with(self, column, search): + return self.where(column, 'LIKE', '%{}'.format(search)) + def group_by(self, *columns): """ Add a "group by" clause to the query