tengo un procedimiento extenso que ejecutandolo directamente en mysql funciona, ahora cuando ya lo pongo en php me da error desde el inicio que es creando una tabla temporal desde donde voy a ir obteniendo datos para lo que sigue del reporte. Este es el código que pruebo y al ejecutar de devuelve OK porque el $stmt -> execute() se esta ejecutando pero la tabla no se crea.
$stmt = Conexion::Conectar()->prepare("CREATE TEMPORARY TABLE
resultado_subdeterminante_temporal
(id int, idSubDeterminante int, posibles int, positivas
int)");
if($stmt -> execute()){
echo 'OK';
} else {
echo 'ERROR';
}
$stmt = null;
Estos son los Log MySql
2018-11-29 17:38:31 18908 [ERROR] Incorrect definition of table
mysql.column_stats: expected column 'min_value' at position 3 to have type
varbinary(255), found type varchar(255).
2018-11-29 17:38:31 18908 [ERROR] Incorrect definition of table
mysql.column_stats: expected column 'max_value' at position 4 to have type
varbinary(255), found type varchar(255).
Ahora si yo tomo esa consulta y la ejecuto en mysql o phpmyadmin se crea ok la tabla:
CREATE TEMPORARY TABLE
resultado_subdeterminante_temporal
(id int, idSubDeterminante int, posibles int, positivas
int)
No comprendo el error, que significan los errores del log?