我试图将选择查询返回的列限制为一列,但 Korma 似乎只是将附加列添加到默认列,而不是仅使用这一列:
=> (dry-run (select games (fields :white_id)))
dry run :: SELECT "games"."stones", "games"."white_id", "games"."black_id", "games"."white_id" FROM "games" :: []
以供参考:
=> (dry-run (select games ))
dry run :: SELECT "games"."stones", "games"."white_id", "games"."black_id" FROM "games" :: []
我希望看到的输出是:
SELECT "games"."white_id" FROM "games";
使用最新的 Korma 0.4.0
我怎么能得到那个?