mirror of
https://github.com/archtechx/laravel-tips.git
synced 2025-12-12 13:24:03 +00:00
13 lines
No EOL
551 B
Markdown
13 lines
No EOL
551 B
Markdown
---
|
|
title: 'You can use Eloquent `whereColumn()` to compare columns to each other'
|
|
tweet_id: '1538579121193701377'
|
|
thread_slug: weekly-thread-2022-24
|
|
author_username: LupinityLabs
|
|
images:
|
|
- 'https://pbs.twimg.com/media/FUw13BSXEAI1_xQ.jpg'
|
|
created_at: 2022-06-19T17:47:02+00:00
|
|
slug: you-can-use-eloquent-wherecolumn-to-compare-columns-to-each-other
|
|
---
|
|
💡🟰 Quick #Laravel Eloquent tip for comparing database columns to each other within a query.
|
|
|
|
You don't have to use any raw statements to do this - whereColumn() has got you covered! 😊 |