All Versions
Latest Version
Avg Release Cycle
83 days
Latest Release
1223 days ago

Changelog History
Page 5

  • v2.0.0-rc1 Changes

    November 30, 2013
    • ๐Ÿ‘ Transaction support
    • ๐Ÿ”ฆ Expose SqlString.format as mysql.format()
    • ๐Ÿ›  Many bug fixes
    • ๐Ÿ‘ Better support for dates in local time zone
    • Doc improvements
  • v2.0.0-alpha9 Changes

    August 27, 2013
    • โž• Add query to pool to execute queries directly using the pool
    • โž• Add sqlState property to Error objects #556
    • Pool option to set queue limit
    • Pool sends 'connection' event when it opens a new connection
    • โž• Added stringifyObjects option to treat input as strings rather than objects (#501)
    • ๐Ÿ‘Œ Support for poolClusters
    • Datetime improvements
    • ๐Ÿ› Bug fixes
  • v2.0.0-alpha8 Changes

    April 30, 2013
    • Switch to old mode for Streams 2 (Node.js v 0.10.x)
    • โž• Add stream method to Query Wraps events from the query object into a node v0.10.x Readable stream
    • DECIMAL should also be treated as big number
    • โœ‚ Removed slow unnecessary stack access
    • โž• Added charsets
    • โž• Added bigNumberStrings option for forcing BIGINT columns as strings
    • ๐Ÿ”„ Changes date parsing to return String if not a valid JS Date
    • โž• Adds support for ?? escape sequence to escape identifiers
    • ๐Ÿ”„ Changes Auth.token() to force password to be in binary, not utf8 (#378)
    • Restrict debugging by packet types
    • โž• Add 'multipleStatements' option tracking to ConnectionConfig. Fixes GH-408
    • ๐Ÿ”„ Changes Pool to handle 'error' events and dispose connection
    • ๐Ÿ‘ Allows db.query({ sql: "..." }, [ val1, ... ], cb); (#390)
    • ๐Ÿ‘Œ Improved documentation
    • ๐Ÿ› Bug fixes
  • v2.0.0-alpha7 Changes

    February 03, 2013
    • โž• Add connection pooling (#351)
  • v2.0.0-alpha6 Changes

    January 31, 2013
    • โž• Add supportBigNumbers option (#381, #382)
    • Accept prebuilt Query object in connection.query
    • ๐Ÿ› Bug fixes
  • v2.0.0-alpha5 Changes

    December 03, 2012
    • โž• Add mysql.escapeId to escape identifiers (closes #342)
    • ๐Ÿ‘ Allow custom escaping mode (config.queryFormat)
    • ๐Ÿ”ง Convert DATE columns to configured timezone instead of UTC (#332)
    • Convert LONGLONG and NEWDECIMAL to numbers (#333)
    • ๐Ÿ›  Fix Connection.escape() (fixes #330)
    • ๐Ÿ”„ Changed Readme ambiguity about custom type cast fallback
    • ๐Ÿ”„ Change typeCast to receive Connection instead of Connection.config.timezone
    • ๐Ÿ›  Fix drain event having useless err parameter
    • โž• Add Connection.statistics() back from v0.9
    • โž• Add back from v0.9
  • v2.0.0-alpha4 Changes

    October 03, 2012
    • ๐Ÿ›  Fix some OOB errors on resume()
    • ๐Ÿ›  Fix quick pause() / resume() usage
    • ๐Ÿ“œ Properly parse host denied / similar errors
    • โž• Add Connection.ChangeUser functionality
    • ๐Ÿ‘‰ Make sure changeUser errors are fatal
    • Enable formatting nested arrays for bulk inserts
    • โž• Add Connection.escape functionality
    • ๐Ÿ“‡ Renamed 'close' to 'end' event
    • ๐Ÿ“œ Return parsed object instead of Buffer for GEOMETRY types
    • ๐Ÿ‘ Allow nestTables inline (using a string instead of a boolean)
    • Check for ZEROFILL_FLAG and format number accordingly
    • โž• Add timezone support (default: local)
    • โž• Add custom typeCast functionality
    • Export mysql column types
    • โž• Add connection flags functionality (#237)
    • Exports drain event when queue finishes processing (#272, #271, #306)
  • v2.0.0-alpha3 Changes

    June 12, 2012
    • ๐Ÿ‘ Implement support for LOAD DATA LOCAL INFILE queries (#182).
    • ๐Ÿ‘Œ Support OLD_PASSWORD() accounts like 0.9.x did. You should still upgrade any user accounts in your your MySQL user table that has short (16 byte) Password values. Connecting to those accounts is not secure. (#204)
    • Ignore function values when escaping objects, allows to use RowDataPacket objects as query arguments. (Alex Gorbatchev, #213)
    • Handle initial error packets from server such as ER_HOST_NOT_PRIVILEGED.
    • Treat utf8\_bin as a String, not Buffer. (#214)
    • ๐Ÿ– Handle empty strings in first row column value. (#222)
    • Honor Connection#nestTables setting for queries. (#221)
    • โœ‚ Remove CLIENT_INTERACTIVE flag from config. Improves #225.
    • ๐Ÿ‘Œ Improve docs for connections settings.
    • ๐Ÿ‘ Implement url string support for Connection configs.
  • v2.0.0-alpha2 Changes

    May 31, 2012
    • Specify escaping before for NaN / Infinity (they are as unquoted constants).
    • ๐Ÿ‘Œ Support for unix domain socket connections (use: {socketPath: '...'}).
    • ๐Ÿ›  Fix type casting for NULL values for Date/Number fields
    • โž• Add fields argument to query() as well as 'fields' event. This is similar to what was available in 0.9.x.
    • ๐Ÿ‘Œ Support connecting to the sphinx searchd daemon as well as MariaDB (#199).
    • ๐Ÿšš Implement long stack trace support, will be removed / disabled if the node core ever supports it natively.
    • Implement nestTables option for queries, allows fetching JOIN result sets with overlapping column names.
    • ๐Ÿ›  Fix ? placeholder mechanism for values containing '?' characters (#205).
    • Detect when connect() is called more than once on a connection and provide the user with a good error message for it (#204).
    • Switch to UTF8_GENERAL_CI (previously UTF8_UNICODE_CI) as the default charset for all connections to avoid strange MySQL performance issues (#200), and also make the charset user configurable.
    • Fix BLOB type casting for TINY_BLOB, MEDIUM_BLOB and LONG_BLOB.
    • โž• Add support for sending and receiving large (> 16 MB) packets.
  • v2.0.0-alpha Changes

    May 15, 2012

    ๐Ÿš€ This release is a rewrite. You should carefully test your application after ๐Ÿš€ upgrading to avoid problems. This release features many improvements, most importantly:

    • ๐Ÿ“œ ~5x faster than v0.9.x for parsing query results
    • ๐Ÿ‘Œ Support for pause() / resume() (for streaming rows)
    • ๐Ÿ‘Œ Support for multiple statement queries
    • ๐Ÿ‘Œ Support for stored procedures
    • ๐Ÿ‘Œ Support for transactions
    • ๐Ÿ‘Œ Support for binary columns (as blobs)
    • Consistent & well documented error handling
    • A new Connection class that has well defined semantics (unlike the old Client class).
    • Convenient escaping of objects / arrays that allows for simpler query construction
    • A significantly simpler code base
    • ๐Ÿ›  Many bug fixes & other small improvements (Closed 62 out of 66 GitHub issues)

    โฌ†๏ธ Below are a few notes on the upgrade process itself:

    The first thing you will run into is that the old Client class is gone and has been replaced with a less ambitious Connection class. So instead of mysql.createClient(), you now have to:

    var mysql      = require('mysql');
    var connection = mysql.createConnection({
      host     : 'localhost',
      user     : 'me',
      password : 'secret',
    connection.query('SELECT 1', function(err, rows) {
      if (err) throw err;
      console.log('Query result: ', rows);

    The new Connection class does not try to handle re-connects, please study the Server disconnects section in the new Readme.

    Other than that, the interface has stayed very similar. Here are a few things to check out so:

    • BIGINT's are now cast into strings
    • Binary data is now cast to buffers
    • The 'row' event on the Query object is now called 'result' and will also be emitted for queries that produce an OK/Error response.
    • Error handling is consistently defined now, check the Readme
    • Escaping has become more powerful which may break your code if you are currently using objects to fill query placeholders.
    • Connections can now be established explicitly again, so you may wish to do so if you want to handle connection errors specifically.

    That should be most of it, if you run into anything else, please send a patch or open an issue to improve this document.