• Davi Arnaut's avatar
    Bug#46385: [Warning] option 'max_join_size': unsigned value 18446744073709551615 adjusted t · 71713f32
    Davi Arnaut authored
    The maximum value of the max_join_size variable is set by converting
    a signed type (long int) with negative value (-1) to a wider unsigned
    type (unsigned long long), which yields the largest possible value of
    the wider unsigned type -- as per the language conversion rules. But,
    depending on build options, the type of the max_join_size might be a
    shorter type (ha_rows - unsigned long) which causes the warning to be
    thrown once the large value is truncated to fit.
    
    The solution is to ensure that the maximum value of the variable is
    always set to the maximum value of integer type of max_join_size.
    
    Furthermore, it would be interesting to always have a fixed type for
    this variable, but this would incur in a change of behavior which is
    not acceptable for a GA version. See Bug#35346.
    71713f32
mysqld.cc 291 KB