This commit is contained in:
Gwendal Roué committed 2019-05-05 20:23:23 +02:00
1 parent 560676a4bb
commit acb7432610
3 files changed
+14

No files matched your search

@@ -179,6 +179,15 @@ extension QueryInterfaceRequest : DerivableRequest, AggregatingRequest {
/// .select([Column("id"), Column("email")])
/// .annotated(with: [Column("name")])
public func annotated(with selection: [SQLSelectable]) -> QueryInterfaceRequest {
// TODO: test consumption of
//
// let author = TableAlias()
// let request = Book
// .annotated(with: [author[Column("name")]])
// .joining(requireed: Book.author)
//
// The problem is the "author.name" column. Can we consume it as "name"?
// From raw rows? From copied rows?
return mapQuery { $0.annotated(with: selection) }
}