lib/primitive.js
function update (table, columns, values) {
    if (this.typecheck) t.typecheck('update', [table, columns, values]);
    if ('string'===typeof columns) {
        columns = [columns];
        values = [values];
    }
    var result = [];
    for (var i=0; i < columns.length; i++) {
        var value = ('string'===typeof values[i]
            // X\'blob\' \'\\xblob\'
            && values[i].indexOf("X\'") != 0 && values[i].indexOf("\'\\x") != 0)
            ? this.string(values[i]) : values[i];
        result.push(columns[i]+'='+value);
    }
    return ['update',table,'set',result.join()].join(' ');
}
function update (table, columns, values) {
    if (this.typecheck) t.typecheck('update', [table, columns, values]);
    if ('string'===typeof columns) {
        columns = [columns];
        values = [values];
    }
    var result = [];
    for (var i=0; i < columns.length; i++) {
        var value = ('string'===typeof values[i]
            // X\'blob\' \'\\xblob\'
            && values[i].indexOf("X\'") != 0 && values[i].indexOf("\'\\x") != 0)
            ? this.string(values[i]) : values[i];
        result.push(columns[i]+'='+value);
    }
    return ['update',table,'set',result.join()].join(' ');
}
function update ( table , columns , values ) { if ( this . typecheck ) t . typecheck ( 'update' , [ table , columns , values ] ) ; if ( 'string' === typeof columns ) { columns = [ columns ] ; values = [ values ] ; } var result = [ ] ; for ( var i = 0 ; i < columns . length ; i ++ ) { var value = ( 'string' === typeof values [ i ] // X\'blob\' \'\\xblob\' && values [ i ] . indexOf ( "X\'" ) != 0 && values [ i ] . indexOf ( "\'\\x" ) != 0 ) ? this . string ( values [ i ] ) : values [ i ] ; result . push ( columns [ i ] + '=' + value ) ; } return [ 'update' , table , 'set' , result . join ( ) ] . join ( ' ' ) ; }
update tbl set col1=val1,col2=val2 ...
update tbl set col1 = val1 col2 = val2 ...