How to add to a SQL Date Bind variable in BI Publisher
When I run the following sql to add days to a bind variable I get an error in BI Publisher but it works in SQL Developer:
with dates as
(
select * from sql_date_table
where (trunc(calendar_dte) >= (:FromLabNotifDate) or 'All' IN (:FromLabNotifDate || 'All'))
and (trunc(calendar_dte) <= TO_DATE(:ToLabNotifDate)+5 or 'All' IN (TO_DATE(:ToLabNotifDate)+5 || 'All'))
order by calendar_dte asc
)
select * from dates
I receive the error:
SQL or ORA exceptions caused due to invalid sql, database package state or some database exceptions
Does any one know what the issue is?