Problema al cargar datos en Crosstab(jasperReport)

abelon25
07 de Septiembre del 2009
�Hola muchachos es mi primer mensaje en esta web y la verdad es un gusto.
I know very little English. sorry� tengo un problema al llenar un reporte espec�ficamente en un crosstable con iReport Estos reportes tienen 2 querys dentro de ellos:

[B]1er query:[/B]

select cApApplicationID as IDAplicacion, dApApplicationName as NombreAplicacion,
(select distinct cTTTransGroup from tmtransactiontype where cTTTransGroup = $P{PIDGrupo}) as IDGrupo,
case (select distinct cTTTransGroup from tmtransactiontype where cTTTransGroup = $P{PIDGrupo})
when '0' then 'Transacciones Financieras'
when '1' then 'Transacciones Administrativas'
end as NombreGrupo
from tmapplication tmapli
where cApApplicationID = $P{PIDAplicacion}



[B]2do query:[/B]

DECLARE @sInputList VARCHAR(8000)
DECLARE @sDelimiter VARCHAR(1)
DECLARE @lstGrupos TABLE (itemG VARCHAR(4) COLLATE Modern_Spanish_CI_AS)
DECLARE @lstCadenas TABLE (itemC INTEGER)
DECLARE @sItemG VARCHAR(4)
DECLARE @sItemC INTEGER

set @sDelimiter = ',';
set @sInputList = $P{idGrupoTarjeta};

WHILE CHARINDEX(@sDelimiter,@sInputList ,0) <> 0
BEGIN
SELECT
@sItemG=RTRIM(LTRIM(SUBSTRING(@sInputList,1,CHARINDEX(@sDelimiter,@sInputList,0)-1))),
@sInputList=RTRIM(LTRIM(SUBSTRING(@sInputList,CHARINDEX(@sDelimiter,@sInputList,0)+LEN(@sDelimiter),LEN(@sInputList))))
IF LEN(@sItemG) > 0
INSERT INTO @lstGrupos SELECT @sItemG
END
IF LEN(@sInputList) > 0
INSERT INTO @lstGrupos SELECT @sInputList -- Put the last item in

set @sInputList = $P{idCadenaComercio};

WHILE CHARINDEX(@sDelimiter,@sInputList ,0) <> 0
BEGIN
SELECT
@sItemC=RTRIM(LTRIM(SUBSTRING(@sInputList,1,CHARINDEX(@sDelimiter,@sInputList,0)-1))),
@sInputList=RTRIM(LTRIM(SUBSTRING(@sInputList,CHARINDEX(@sDelimiter,@sInputList,0)+LEN(@sDelimiter),LEN(@sInputList))))
IF LEN(@sItemC) > 0
INSERT INTO @lstCadenas SELECT CAST(@sItemC as INTEGER)
END
IF LEN(@sInputList) > 0
INSERT INTO @lstCadenas SELECT CAST(@sInputList as INTEGER)-- Put the last item in


select $P{PIDGrupo} as IDGrupo,
$P{PIDAplicacion} as IDAplicacion,
cast(tbAplica.dApApplicationName as varchar(20)) as NombreAplicacion ,
tbTransType.cTTTransactionId as IDTransaccion ,
tbTransType.dTTTransactionName as NombreTransaccion,
FE.anho as AñoTransaccion,
FE.mes as MesTransaccion,
FE.anho + FE.mes as FechaTransaccion,
(
select count(*) from tptransactionlog tp WITH (NOLOCK) where tp.cTxTxnGroup = $P{PIDGrupo}
and tp.cTxAplicacion = $P{PIDAplicacion}
and tp.cTxType = tbTransType.cTTTransactionId
and substring(tp.fTxTxnDateHour,1,6) = FE.anho +FE.mes
and tp.fTxTxnDateHour BETWEEN $P{PFechaInicial}+ '000000' AND $P{PFechaFinal}+'235959'
and ($P{PResultado}='%%' or tp.ctxresultext = $P{PResultado})
and tp.ctxresultext <> $P{PDiferente}
) as CantTrax
from (
select cApApplicationID, dApApplicationName
from tmApplication
where cApApplicationID = $P{PIDAplicacion}
) tbAplica,
DBO.FECHAS($P{PFechaInicial},$P{PFechaFinal}) FE,
(
select cTTTransactionId, dTTTransactionName
from tmTransactionType tbtt
where tbtt.cTTAplicacion = $P{PIDAplicacion}
and tbtt.cTTTransGroup = $P{PIDGrupo}
) tbTransType
group by tbAplica.dApApplicationName, tbTransType.cTTTransactionId, tbTransType.dTTTransactionName, FE.anho, FE.mes
order by IDGrupo, IDAplicacion, tbTransType.cTTTransactionId, tbTransType.dTTTransactionName, FechaTransaccion

/****************************************************/

estos querys estan en un CrossTable dentro del reporte. Me han pedido que estos querys ya no esten en el reporte, sino en la aplicacion java, crear un metodo o 2, todos los datos est&#65533;n cargados en sesi&#65533;n pero el reporte no lo reconoce como si no los estuviera capturando, ya hice lo ultimo(crear un m&#65533;todo para el 2do query en el DAO) pero al realizar la consulta la aplicacion no me muestra el reporte y en el output de netBeans no me muestra ningun error o algo de ayuda para ver el problema. bueno ojala me puedan ayudar se los agradezco de antemano y si falta algun tipo de dato para resolver este tema se los hare llegar