Bradley Grainger

Results 329 comments of Bradley Grainger

I'm adding support for `MemoryStream`. If `TryGetBuffer` succeeds, that will be written directly to the packet (which should be efficient). Otherwise, `ToArray()` will be called, which will duplicate all the...

`MemoryStream` is in 1.3.0-beta.4: https://www.nuget.org/packages/MySqlConnector/1.3.0-beta.4 [MySqlBulkCopy](https://mysqlconnector.net/api/mysqlconnector/mysqlbulkcopytype/) is the closest thing to streaming that MySqlConnector has; the right way to support `Stream` is probably to allow it to be part of...

`DataTable` is just currently the public API for `MySqlBulkCopy`; it wouldn't be a hard requirement.

> Assuming it’s possible to copy the data via the MySQL wire protocol via a 64K buffer and avoid the max packet size issues, I think that’s the best approach....

I don't think so, since from that page: > The `max_allowed_packet` system variable controls the maximum size of parameter values that can be sent with `mysql_stmt_send_long_data()`. EDIT: This may just...

A good point from that SO question: > Still, even if I manage to INSERT, say, 20MB BLOB with `max_allowed_packet=4MB` how do I SELECT it back? I don't see how...

> You can already receive large data as it’s already possible with the connector to read data into a stream. No, because there's no way for the server to send...

> people say it works for Java and PHP, so it must be possible? I can look into implementing `mysql_stmt_send_long_data` in MySqlConnector. It only works for the "binary" protocol, so...

The documentation for `COM_STMT_SEND_LONG_DATA`: https://dev.mysql.com/doc/internals/en/com-stmt-send-long-data.html MySqlConnector could determine if a prepared command had a `Stream` supplied for any parameter. If so, it could send the data from the stream in...

> MySqlConnector could determine if a prepared command had a `Stream` supplied for any parameter. If so, it could send the data from the stream in repeated chunks using `COM_STMT_SEND_LONG_DATA`....