Skip to content

Commit

Permalink
Add insertIgnoreConflict to IDBConnection interface.
Browse files Browse the repository at this point in the history
Signed-off-by: Ole Ostergaard <[email protected]>
  • Loading branch information
oole committed Feb 26, 2019
1 parent e48cc51 commit 6247745
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions lib/public/IDBConnection.php
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,20 @@ public function lastInsertId($table = null);
*/
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
*
Expand Down

0 comments on commit 6247745

Please sign in to comment.