Skip to content

Commit

Permalink
add erase-from helper #532
Browse files Browse the repository at this point in the history
Signed-off-by: Sean Corfield <[email protected]>
  • Loading branch information
seancorfield committed Nov 23, 2024
1 parent 129239a commit 09fa8af
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/honey/sql/helpers.cljc
Original file line number Diff line number Diff line change
Expand Up @@ -592,6 +592,15 @@
[& args]
(generic :delete-from args))

(defn erase-from
"For erasing (hard delete) from a single table (XTDB).
Accepts a single table name to erase from.
(-> (erase-from :films) (where [:= :id 1]))"
{:arglists '([table])}
[& args]
(generic :erase-from args))

(defn truncate
"Accepts a single table name to truncate."
{:arglists '([table])}
Expand Down

0 comments on commit 09fa8af

Please sign in to comment.