cost 51 ms
如何構建雄辯的查詢以檢索主表的記錄,在Laravel 5 PHP中對其相關表應用where子句?

[英]How to build Eloquent query to retrieve records of the main table, applying where clause on it's related table in Laravel 5 PHP?

使用Laravel文檔中的示例多對多relaltionshiop數據庫結構,如下所示: 我想檢索post.name LIKE %laravel%或tags.name LIKE %laravel% post記錄。 如何使用口才模型來建立這樣的查詢? 這對我來說是一個很大的挑戰,因為 ...


排序:
質量:
 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM