Ver original$fecha = date("Y-m");
Ver originalSELECT SUM(campo) FROM tabla WHERE date_format(fecha, '%Y-%m') = '$fecha'