3
I have a field DATETIME
with a date and time: 2015-08-06 08:50:28
. I’m trying to generate a report by passing two parameters, Data_Inicial
and Data_Final
so that I can get all the bank dates that are in that period.
The condition was that way in the IReport
:
WHERE
tbl_suspensao.`status` = 'Finalizado'
AND tbl_suspensao.`data_inicio` BETWEEN $P{Data_Inicio} AND $P{Data_Fim}
These two parameters are of the type: Date/Time
of java.sql.Time
. But when I enter the parameters and give a preview appears the message "The document has no pages". Someone can help?
Take a test of
data_inicio 01/01/2015
anddata_fim 12/12/2015
– Maicon Carraro
Give the same message saying that the document does not contain pages
– DiegoAugusto
So your problem is not on the dates no little grasshopper, are you sure that this condition is valid
tbl_suspensao.status = 'Finalizado'
?– Maicon Carraro
I do, when I leave it alone it works perfectly. I did a test and put the type of the parameter as just
DATE
and it worked, but I can’t establish the hours.– DiegoAugusto
I’ve changed and worked rsrs, but we can not use the with the schedule. But I’ll leave it that way anyway. Repurposing the question, how could I count in the report itself how many Customers have status = 'Finished' and how many have status = 'Pending' ?
– DiegoAugusto
You have to give a Count on
status
grouping together bystatus
– Maicon Carraro
But I advise you to create another question so as not to pollute this
– Maicon Carraro
I tried to give a Count in status but it counts all independently whether it is Finalized or Pending. The expression stayed this way in the status field I added in the band sumary:
$V{tbl_suspensao_status_2}
– DiegoAugusto
I get it. I’ll try to do it if I don’t work I open another question.
– DiegoAugusto
You can answer this question since you also helped me to reach the solution. Or you prefer that I answer?
– DiegoAugusto
Can you even :}
– Maicon Carraro