summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorOle Ostergaard <ole.c.ostergaard@gmail.com>2019-02-26 16:27:25 +0100
committerOle Ostergaard <ole.c.ostergaard@gmail.com>2019-03-21 11:42:00 +0100
commit63350423d48b1d4fef842666ae3b7627396ca8d1 (patch)
tree1c89c4cc7690c6f22851e67ff8fdf21edf97499c /lib
parentd62da82bf9e44d62aff287dcf64dccef35c2d693 (diff)
downloadnextcloud-server-63350423d48b1d4fef842666ae3b7627396ca8d1.tar.gz
nextcloud-server-63350423d48b1d4fef842666ae3b7627396ca8d1.zip
Add insertIgnoreConflict to IDBConnection interface.
Signed-off-by: Ole Ostergaard <ole.c.ostergaard@gmail.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/public/IDBConnection.php14
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/public/IDBConnection.php b/lib/public/IDBConnection.php
index b3abe464845..f640ec126f0 100644
--- a/lib/public/IDBConnection.php
+++ b/lib/public/IDBConnection.php
@@ -120,6 +120,20 @@ interface IDBConnection {
*/
public function insertIfNotExist($table, $input, array $compare = null);
+
+ /**
+ *
+ * Insert a row if the row does not exist. Eventual conflicts during insert will be ignored.
+ *
+ * Implementation is not fully finished and should not be used!
+ *
+ * @param string $table The table name (will replace *PREFIX* with the actual prefix)
+ * @param array $input data that should be inserted into the table (column name => value)
+ * @return int number of inserted rows
+ * @since 17.0.0
+ */
+ public function insertIgnoreConflict($table, $input) : int;
+
/**
* Insert or update a row value
*