servicex_utils v0.1.0 ServicexUtils.Ecto.EctoUtil

Ecto関連の操作機能

Link to this section Summary

Functions

SQL直接実行

information

EctoのSQLビルダを使用せずにSQLを直接実行する Ecto.Adapters.SQL.query()のWrapper関数 戻り値を[%{row1},%{row2}…]形式で返す。

Link to this section Functions

Link to this function query(repo, sql, params)
query(Repo, string(), [list()]) :: [list()]

SQL直接実行

information

EctoのSQLビルダを使用せずにSQLを直接実行する Ecto.Adapters.SQL.query()のWrapper関数 戻り値を[%{row1},%{row2}…]形式で返す。

Examples

iex> EctoUtil.query(MyApp.Repo, "select * from users", params)
[${id: => 1, name: => "userA name" },${id: => 2, name: => "userB name" }]