如何用 Doctrine 翻译这个查询?
我尝试生成自定义查询(我正在为网站开发搜索引擎)。
这是要翻译的查询:
SELECT * FROM `offre_habitation`
WHERE `id_type_offre` = 2
AND `id_nature_offre` = 1
AND (`nb_pieces` = 2 or `nb_pieces` = 1 or `nb_pieces` = 3 or `nb_pieces` = 4)
AND (`id_secteur`=1 OR `id_secteur` = 2 or id_secteur = 3)
AND `surface_habitable` > 90
AND `prix` > 700
你能帮我吗?
I try to generate a custom query (I'm developing a search engine for a website).
This is te query to translate :
SELECT * FROM `offre_habitation`
WHERE `id_type_offre` = 2
AND `id_nature_offre` = 1
AND (`nb_pieces` = 2 or `nb_pieces` = 1 or `nb_pieces` = 3 or `nb_pieces` = 4)
AND (`id_secteur`=1 OR `id_secteur` = 2 or id_secteur = 3)
AND `surface_habitable` > 90
AND `prix` > 700
Could you help me please ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
未经测试,但类似这样的东西应该可以解决问题:
...这利用了这样一个事实:例如:
...与以下内容相同:
Not tested, but something like this should do the trick:
...this makes use of the fact that, for example:
...is the same as: