uuid icon indicating copy to clipboard operation
uuid copied to clipboard

Enhancement: Support binary SQL representation

Open mcandre opened this issue 5 years ago • 2 comments

Binary UUID format in SQL has much better performance than text UUID format in SQL. Could we get support for seamless binary UUID marshaling?

mcandre avatar Apr 05 '19 16:04 mcandre

Can you please describe what "Binary UUID format in SQL" means and what "seamless" marshaling might look like?

cbandy avatar Sep 04 '19 21:09 cbandy

@cbandy if you create uuid in mysql as binary(16), then drivers are waiting for byte[16], not string, which is returned by default from Value(). But we cannot just replace, cause it depends on driver. Global flag is also not a good solution, because if you use multiple drivers in the solution it's going to be a hell.

Thinks became more tricky if you use gorm. You do not send values explicitly.

ZzEeKkAa avatar Mar 10 '21 07:03 ZzEeKkAa