+ 2
How do you write a code to pull data that is over a year old? (Comparing to 2 different date columns)
working on some code in Microsoft Access database 2013 and I am stumped on how to pull up records over a year old using 2 different date columns to generate a table of data with one or the other date being over a year old
12 Antworten
+ 30
select * from emp where year(date)>=year(curdate())-1;
//hope it works☺
+ 2
Select * from EMPLOYEE
where JOINING_DATE >to_date('31/01/2013','dd/mm/yyyy'
Select * from EMPLOYEE
where JOINING_DATE <to_date('31/01/2013','dd/mm/yyyy'
Hi Bro
u have to mentioned date of joining . which DOJ u required
+ 1
I've been trying to use dateadd("yyyy",-1,Date())
I messed up tho with my question, it's more complicated than I made it seem.
It's written like this
where ((column A) like "Z*") and ((column b) is not null) and ((column c) is null) and [this is where I need to compare to see if column d or e are over 1 year old]
+ 1
Plz try which sent
+ 1
I updated the question to be more specific on what I'm trying to do, sorry.
+ 1
Bro you are awesome can you teach me please
+ 1
have u tried as per above
+ 1
no bro im a learner i know some basics but i want to know THE EXACT use of java
+ 1
I don't know about Java
+ 1
ohh that's okay
+ 1
Well, I got it to work thanks to Gaurav's answer, except I had to use Date() instead of curdate()
0
try it