We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cf84c90 commit 95d8ed1Copy full SHA for 95d8ed1
sql/types/conversion.go
@@ -642,6 +642,10 @@ func GeneralizeTypes(a, b sql.Type) sql.Type {
642
if b == Null {
643
return a
644
}
645
+
646
+ if a == b {
647
+ return a
648
+ }
649
650
if svt, ok := a.(sql.SystemVariableType); ok {
651
a = svt.UnderlyingType()
@@ -716,6 +720,11 @@ func GeneralizeTypes(a, b sql.Type) sql.Type {
716
720
if IsNumber(a) && IsNumber(b) {
717
721
return generalizeNumberTypes(a, b)
718
722
723
724
+ if IsText(a) || IsText(b) {
725
726
727
719
728
// TODO: decide if we want to make this VarChar to match MySQL, match VarChar length to max of two types
729
return LongText
730
0 commit comments