sql - Oracle: Get data for only the past half year -


i writing query in have data last half year: data current date , half year ago. found 1 year in sql it's not working in oracle:

select ... ... date > dateadd(year,-1,getdate()) 

the equivalent function dateadd add_months

select ... ... date > add_months(sysdate, -6) 

Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -