diff --git a/Readme.md b/Readme.md index 78291ab8f..c415bf1e3 100644 --- a/Readme.md +++ b/Readme.md @@ -850,9 +850,21 @@ connection.query({ } }); ``` +__WARNING: YOU MUST INVOKE the parser using one of these three field functions in your custom typeCast callback. They can only be called once.( see #539 for discussion)__ + +``` +field.string() +field.buffer() +field.geometry() +``` +are aliases for +``` +parser.parseLengthCodedString() +parser.parseLengthCodedBuffer() +parser.parseGeometryValue() +``` +__You can find which field function you need to use by looking at: [RowDataPacket.prototype._typeCast](https://github.com/felixge/node-mysql/blob/master/lib/protocol/packets/RowDataPacket.js#L41)__ -If you need a buffer there's also a `.buffer()` function and also a `.geometry()` one -both used by the default type cast that you can use. ## Connection Flags