[5.2] Add whereColumn clause#13549
Conversation
|
|
|
Ah, but it's not only about egality. So maybe |
|
It's supposed to function like a sentence: "where column first_name equals (to the column) last_name". |
|
It's much clearer, once having kept this in mind. |
|
For a regular Whatever we do, it should be consistent between these two methods. |
|
A while ago a regular where was updated to allow for the syntax I mentioned above. Since whereColumn is using the same array parsing logic as the normal where, it's entirely consistant. |
|
Oh you're right. Didn't know about that. Learn something new every day 💯 |
If we want to compare two columns inside a where clause, we now need to write a raw expression:
But with this PR we can use a new
whereColumnmethod:As with normal where clauses, array conditions can be passed as well: