Oracle SQL Developer中的右括号错误

问题描述 投票:0回答:1
SELECT titol, data_prestec FROM if_llibres, if_llibre_prestec
WHERE if_llibre_prestec.ubicacio = if_llibres.ubicacio
AND data_devolucio IS NULL
AND data_prestec <= date_sub(current_date(),interval 30 day);
oracle date oracle-sqldeveloper intervals
1个回答
0
投票

Oracle中没有DATE_SUB()函数。您可以将其表达为:

select 
    titol, 
    data_prestec 
from if_llibres il
inner join if_llibre_prestec ilp 
    on ild.ubicacio = il.ubicacio 
where 
    data_devolucio is null 
    and data_prestec <= current_date - interval '30' day; 
© www.soinside.com 2019 - 2024. All rights reserved.