ibdknox/Korma — Issue #25: Update statement is messing up positions
Author: nshah
Created: 2011-11-20 23:52:01+00:00
State: open

I'm not sure if I'm doing something wrong, but I'm seeing some bad behavior with 0.3.0-alpha2:

user=> (dry-run (update article (set-fields {:slug "foo" :title "bar"}) (where {:slug "foo"})))
dry run :: UPDATE "article" SET "title" = ?, "slug" = ? WHERE ("article"."slug" = ?) :: [foo bar foo][{:id 1}]

user=> (dry-run (update article (set-fields {:title "bar" :keywords "a"}) (where {:slug "foo"})))
dry run :: UPDATE "article" SET "title" = ?, "keywords" = ? WHERE ("article"."slug" = ?) :: [foo bar a]

user=> article
{:table "article", :name "article", :pk :id, :db nil, :transforms (), :prepares (), :fields [], :rel {}}

Let me know if I can provide more information.