Search code examples
sqldateobieerestriction

Restrict data of all months based on current day of month in Obiee


How can I restrict the data of all the months based on Current day of month. Supposed day of month is 18 so all previous months will give me data only till 18th and not more than that in Obiee?


Solution

  • You can use extract():

    select t.*
    from t
    where extract(day from datecol) <= extract(day from sysdate);