I am working on a project where I have a table market which has a buyer_id column and a seller_id column. When a seller puts something on the market, the seller_id and buyer_id
In recent Laravel versions you can use whereColumn (docs):
whereColumn
$same = Market::whereColumn('seller_id', 'buyer_id')->get();