E0
V2EX  ›  问与答

Python 的 orator 如何构造多个 like 查询?

  •  
  •   E0 · Jul 17, 2022 · 1746 views
    This topic created in 1436 days ago, the information mentioned may be changed or developed.

    原生语句:

    SELECT * FROM `think_user` WHERE  (`name` LIKE '%think%' OR `name` LIKE '%php%')
    

    在 orator 中该怎么写?翻文档没找到。

    1 replies    2022-07-18 02:47:08 +08:00
    Trim21
        1
    Trim21  
       Jul 18, 2022 via Android
    .where(…).or_where(…)
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2850 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 39ms · UTC 15:13 · PVG 23:13 · LAX 08:13 · JFK 11:13
    ♥ Do have faith in what you're doing.