SELECT Concepto, SUM(CASE WHEN TipoMovto = 0 THEN Importe END) AS CARGO, SUM(CASE WHEN TipoMovto = 1 THEN Importe END) AS ABONO FROM MovimientosPoliza GROUP BY Concepto;