Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在这里有一个查询,我正在尝试进行查询,但我无法让它正常工作。
所以基本上我想要做的是在给定的负 30 天的日期之间进行查询......所以在给定的负 30 天的日期之间的任何内容。
在我的查询中,我想确保RSLVD_DTTM等于TICKETDATE或在TICKETDATE.
RSLVD_DTTM
TICKETDATE
例子。
RSLVD_DTTM = TICKETDATE BETWEEN TICKETDATE - 30 DAYS
任何帮助,将不胜感激。
谢谢
您没有指定 DBMS,所以这是 ANSI SQL
where RSLVD_DTTM between TICKETDATE - interval '30' DAY and TICKETDATE