SQL JOIN - WHERE clause vs. ON clause

前端 未结 19 1629
深忆病人
深忆病人 2020-11-21 11:56

After reading it, this is not a duplicate of Explicit vs Implicit SQL Joins. The answer may be related (or even the same) but the question is diffe

19条回答
  •  闹比i
    闹比i (楼主)
    2020-11-21 12:56

    On INNER JOINs they are interchangeable, and the optimizer will rearrange them at will.

    On OUTER JOINs, they are not necessarily interchangeable, depending on which side of the join they depend on.

    I put them in either place depending on the readability.

提交回复
热议问题