Jump to content
We've recently updated our Privacy Statement, available here ×

Incorrect date results


chenny

Recommended Posts

Hi,

I am using iReport 3.0.0 and JasperServer 3.0.0 with Postgresql 8.3. My report query is

 

select rapiderp.findstartperiod($P{periodID}) , rapiderp.findendperiod($P!{periodID})::date as aging_run_date, ar.customerid as aging_customerid, cu.name as customers_name,cu.name_ch as name_chinese,  cu.agentgroupid as customers_agentgroupid, ag.groupname,
sum(case when ar.period_id<$P{periodID} then ar.amount else 0.00 end) as aging_openingbalance,
sum(case when ar.period_id<=$P{periodID} then ar.amount else 0.00 end) as aging_closingbalance,
sum(case when ar.period_id=$P{periodID} and ar.sourcetype='IN' and iv.invoice_balance is not null then iv.totalamount-coalesce(
(select sum(rd.amount) from rapiderp.receiptdetails rd, rapiderp.receipts rr where rr.receiptid=rd.receiptid and rd.sourceidapplied=iv.invoiceno
    and rr.period_id<=$P{periodID}),0.00)::numeric else 0.00 end)...........

 

 

IF the periodID is 152 ....it should result in the rapiderp.findendperiod($P{periodID}) as '2008-07-31'::date. But it always display as

2007-07-30 in the reports.

or perodID=153 ..-> 2008-08-31 .....print out as "2008-08-30".

 

Please assist ..

 

Regards

 

David

Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Popular Days

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...