Closed pavarnos closed 7 years ago
@pavarnos I have a question here.
Do we really need trait or can we just add these methods to AbstractQuery class ?
Could do. But where() / orWhere() is not used by Insert so the methods do not make any sense on that class. So then we'd need to have some way to hide them from the public interface of the Insert class? Similarly with limit/offset. ValuesInterface is used by Insert and Update (and potentially by Select) but not by Delete. So there is no obvious hierarchy.
Its just an idea. Delete the PR if you think it is going in the wrong direction.
Sorry I didn't thought more about that :) .
could also do similar for ReturningInterface, which is only used by pgsql... but yeah, how far should we go?
could do similar for LimitInterface, LimitOffsetInterface and ValuesInterface.