db::replace PHP Method

replace() static public method

Runs a REPLACE query
static public replace ( string $table, mixed $input ) : mixed
$table string The table name
$input mixed Either a key/value array or a valid MySQL insert string
return mixed The last inserted id if everything went fine or an error response.
    static function replace($table, $input)
    {
        return self::execute('REPLACE INTO ' . self::prefix($table) . ' SET ' . self::values($input));
    }