This will be very heavily dependent on the Operating System you're running on, and the DBMS software you are using. Some database systems include support for doing this kind of thing, while some don't.
If you're running on Linux or Unix, you can often get some great results by using cron for scheduling and running Perl or shell scripts. It's pretty easy, especially with Perl, to run a script, look for specific things in the query results, and then send an e-mail if needed.
I've used this setup (cron + Perl) successfully on numerous occasions on Linux/Unix using PostgreSQL, Oracle, and MySQL.
[Note: I use "Perl" above because I really like Perl, and it works great for me. If you are better with shell scripts, python, ruby, or [insert your favorite language here], use that. Pretty much anything that can interface with the database will probably work.]