diff --git a/wp-includes/version.php b/wp-includes/version.php index 88d62fc71b..63bf8c80dd 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.9-alpha-41483'; +$wp_version = '4.9-alpha-41496'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. diff --git a/wp-includes/wp-db.php b/wp-includes/wp-db.php index c300e240f2..9d125d008d 100644 --- a/wp-includes/wp-db.php +++ b/wp-includes/wp-db.php @@ -1252,6 +1252,7 @@ class wpdb { $query = str_replace( '"%s"', '%s', $query ); // doublequote unquoting $query = preg_replace( '|(?prepare( "CONVERT( LEFT( CONVERT( %s USING $charset ), %.0f ) USING $connection_charset )", $value['value'], $value['length']['length'] ); + $length = sprintf( '%.0f', $value['length']['length'] ); + $queries[ $col ] = $this->prepare( "CONVERT( LEFT( CONVERT( %s USING $charset ), $length ) USING $connection_charset )", $value['value'] ); } else if ( 'binary' !== $charset ) { // If we don't have a length, there's no need to convert binary - it will always return the same result. $queries[ $col ] = $this->prepare( "CONVERT( CONVERT( %s USING $charset ) USING $connection_charset )", $value['value'] );