News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Query Inactive Members?

Started by Minion, August 06, 2003, 11:36:14 PM

Previous topic - Next topic

Minion

Trying to get emails of board members who have not been active for quite some time.

Trying to use this:

SELECT  * FROM  `yabbse_members`.emailAddress  WHERE  `lastLogin`  > NULL;

Am I doing this right?
How do i select via the value "NULL"?

Thanks in advance!

[Unknown]

SELECT  emailAddress FROM  `yabbse_members`  WHERE  `lastLogin` IS NOT NULL;

???

I would rather say...

SELECT emailAddress
FROM yabbse_members
WHERE lastLogin IS NULL
  OR lastLogin < UNIX_TIMESTAMP('2003-05-01');

But that would be inaccurate.

-[Unknown]

Minion

Thanks unknown.
That did the trick.

Advertisement: