Add ability to override the `FROM` clause on select queries, refs #290