views:

54

answers:

2

Hello I need to write a program that checks a access .mdb file and when a specific row is added (say the "name" field column of the newly added a row that contains a specific string, it should send an email to a specific address.

For this I am planning to use "Jackcess" library for reading the mdb file and "Apache's commons-email library" for SMTP mailing. However I am not sure which library of Java can be used to execute this "row check" every X time.

Thanks

+2  A: 

If you're happy for the program to run continuously, I'd use Quartz (http://www.opensymphony.com/quartz/). Otherwise a cronjob...

Jim Downing
+1  A: 

Jcrontab might work for you, as you can keep it all in your java application. (This would assume your app is always running, and you want it to periodically check the file while doing other things too. Like in a webapp.)

Jcrontab is a scheduler written in Java. The project objective is to provide a fully functional schedules for Java projects.

Stu Thompson