logo
  • 教程列表
  • SO官方文檔
  • 外生
    • 在 elixir 程式中新增 Ecto.Repo
    • 和 Repo.get 中的子句 by3
    • 查詢動態欄位
    • 將自定義資料型別新增到遷移和架構
  1. StackOverflow 文件
  2. Elixir Language 教程
  3. 外生
  4. 查詢動態欄位

查詢動態欄位

Created: November-22, 2018

要查詢變數中包含名稱的欄位 ,請使用欄位函式 。

some_field = :id
some_value = 10

from p in Post, where: field(p, ^some_field) == ^some_value
  • 將自定義資料型別新增到遷移和架構
  • 和 Repo.get 中的子句 by3

Copyright © 2018. All right reserved

tastones.com 备案号:鲁ICP备18045372号-1

  • 關於本站
  • 免責聲明