Hi friends,
i need your help..
i have to write a query to fetch records from database
by comparing their time stamp and current date..
condition is
greater than 24hrs and less than 48 hrs
SELECT *
FROM data
WHERE timestamp
BETWEEN
DATE_SUB( NOW( ) , INTERVAL 1 DAY )
AND Now()
SELECT *
FROM data
WHERE timestamp > DATE_SUB( NOW( ) , INTERVAL 1
DAY )
AND is_email_verified =0
AND DATE_SUB( NOW( ) , INTERVAL 2
DAY ) < timestamp
the above are the two ways i tried to write query but no proper result
it is resulting the users data who have registered today also