     ///     // SELECT target.*
     ///     // FROM target
     ///     // WHERE target.originId = 1
+    ///
+    /// This method works for simple direct associations such as BelongsTo or
+    /// HasMany in the above examples, but also for indirect associations such
+    /// as HasManyThrough, which have any number of pivot relations between the
+    /// origin and the target.
     func targetRelation(from originAlias: TableAlias, rows originRows: @escaping (Database) throws -> [Row]) -> SQLRelation {
         // Filter the pivot
         let pivot = steps[0]

    ///     // SELECT origin.*, target.*
    ///     // FROM origin
    ///     // JOIN target ON target.originId = origin.id
    func joinedRelation(from origin: SQLRelation, required: Bool) -> SQLRelation {
        let targetJoin = SQLJoin(
            isRequired: required,

        return reducedAssociation.joinedRelation(from: origin, required: required)
    }
    
    /// Given an origin alias and rows, returns the target of the association
    /// as a relation.
    ///
    /// This method provides support for association methods such
    /// as `request(for:)`:
