Skip to content

Commit c46b45b

Browse files
authored
Merge pull request diesel-rs#1254 from diesel-rs/sg-update-join-docs
Update some out of date info on our Join DSL docs
2 parents dd8b9a0 + 1873fbf commit c46b45b

1 file changed

Lines changed: 9 additions & 3 deletions

File tree

diesel/src/query_dsl/join_dsl.rs

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,12 @@ where
4646

4747
/// Methods allowing various joins between two or more tables.
4848
///
49-
/// Joining between two tables requires a [`#[belongs_to]`
50-
/// association][associations] that defines the relationship.
49+
/// If you have invoked [`joinable!`] for the two tables, you can pass that
50+
/// table directly. Otherwise you will need to use [`.on`] to specify the `ON`
51+
/// clause.
52+
///
53+
/// [`joinable!`]: ../macro.joinable.html
54+
/// [`.on`]: trait.JoinOnDsl.html#method.on
5155
///
5256
/// You can join to as many tables as you'd like in a query, with the
5357
/// restriction that no table can appear in the query more than once. The reason
@@ -114,7 +118,9 @@ impl<T: AsQuery> JoinDsl for T {}
114118

115119
pub trait JoinOnDsl: Sized {
116120
/// Specify the `ON` clause for a join statement. This will override
117-
/// any implicit `ON` clause that would come from `#[belongs_to]`
121+
/// any implicit `ON` clause that would come from [`joinable!`]
122+
///
123+
/// [`joinable!`]: ../macro.joinable.html
118124
///
119125
/// # Example
120126
///

0 commit comments

Comments
 (0)