我该如何查询在Laravel中构建
如果我想在sql中做这样的事情: 从表中选择 * id = 1111 (列1为null或column2 ='sample')
我尝试使用“ - > wery(..) - > orwherenull(...)
If i want to make something like this in sql:
SELECT * FROM table
WHERE id = 1111
AND (column1 is null OR column2 = 'sample')
I try with "->where(..)->orWhereNull(...)", but it is not my point (like without () is query)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在Laravel中使用逻辑分组,谢谢Aynber:
Use Logical Grouping in Laravel, thanks aynber: