diff --git a/src/main/scala/io/izzel/taboolib/module/db/sql/query/QueryDelete.java b/src/main/scala/io/izzel/taboolib/module/db/sql/query/QueryDelete.java index 5ed81f5..ec2ba97 100644 --- a/src/main/scala/io/izzel/taboolib/module/db/sql/query/QueryDelete.java +++ b/src/main/scala/io/izzel/taboolib/module/db/sql/query/QueryDelete.java @@ -31,6 +31,10 @@ public class QueryDelete { return this; } + public void run(DataSource dataSource) { + to(dataSource).run(); + } + public RunnableUpdate to(DataSource dataSource) { return new RunnableUpdate(toQuery()).dataSource(dataSource).statement(s -> { int index = 1; diff --git a/src/main/scala/io/izzel/taboolib/module/db/sql/query/Where.java b/src/main/scala/io/izzel/taboolib/module/db/sql/query/Where.java index 41a657a..11a2526 100644 --- a/src/main/scala/io/izzel/taboolib/module/db/sql/query/Where.java +++ b/src/main/scala/io/izzel/taboolib/module/db/sql/query/Where.java @@ -35,10 +35,18 @@ public class Where { return new Where(row, "=", value); } + public static Where equals(String row, Object value) { + return new Where(row, "=", value); + } + public static Where isNot(String row, Object value) { return new Where(row, "<>", value); } + public static Where equalsNot(String row, Object value) { + return new Where(row, "<>", value); + } + public static Where more(String row, Object value) { return new Where(row, ">", value); }