Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

XL Reporter : Date critaries aren't working correctly


yesterday I found a bug in my reports. I wanted to show all transactions between two dates : 08/01/07 and 08/14/07 but the query retrieves records it shouldn't

FACT JOU( RefDate >= @Date1 And RefDate <= @Date2 And TransTypeCode = "ARInvoice" Or TransTypeCode = "ARCreditMemo" Or TransTypeCode = "CashReceipt" ) Group By JOU.RefDate ,JOU.TransTypeCode ,FIG.OJDT_BaseRef ,FIG.OJDT_Ref1 ,FIG.OJDT_Ref2

But when I do a similar SQL query using the cast as Datetime, it works perfectly. Isn't there a way to do something like this with XL Reporter ?

select RefDate,Memo from dbo.OJDT where RefDate >= cast('05/01/2007' as Datetime) and RefDate <= cast('08/14/2007' as Datetime) and TransId in (select TransId from OJDT where Memo like 'A/R I%' or Memo like 'A/R C%' or Memo like 'Inc%')

Is anyone had the same kind of problems as me with dates ? Do you have any solutions.

Former Member

Helpful Answer

Not what you were looking for? View more on this topic or Ask a question