This week's book giveaway is in the OCAJP 8 forum.
We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line!
See this thread for details.
The moose likes JDBC and Relational Databases and the fly likes Regarding send a mail automatically for birthdays before 3 days Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "Regarding send a mail automatically for birthdays before 3 days" Watch "Regarding send a mail automatically for birthdays before 3 days" New topic
Author

Regarding send a mail automatically for birthdays before 3 days

surya.raaj prakash
Ranch Hand

Joined: Oct 30, 2009
Posts: 76
HI Friends,

I have one requirement,i.e How to create SOL Query send a mail automatically for birthdays before 3 days?

Ulf Dittmer
Rancher

Joined: Mar 22, 2005
Posts: 42958
    
  73
SQL and JDBC are for accessing databases, not for sending mails; check out the JavaMail API for that (the JavaEnterpriseEditionFaq has helpful links about it).
Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 32635
    
215

Or are you asking how to do a query to get dates less than 3 days away? If so, what database are you using? Have you looked at the date functions for that database?


[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
surya.raaj prakash
Ranch Hand

Joined: Oct 30, 2009
Posts: 76
Jeanne Boyarsky wrote:Or are you asking how to do a query to get dates less than 3 days away? If so, what database are you using? Have you looked at the date functions for that database?


Hi Jeanne Boyarsky,

Yes,
MySql,
yes,I have looked at date functions but i couldn't get the right query to to send mail before 3 days..
Ulf Dittmer
Rancher

Joined: Mar 22, 2005
Posts: 42958
    
  73
OK, so the problem has nothing to do with sending emails, and everything to do with writing a SELECT statement. Post the statement you have used so far, and describe which records it -correctly or incorrectly- selects. Also tell us the data types and sample values of the involved attributes.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Regarding send a mail automatically for birthdays before 3 days
 
It's not a secret anymore!