Hi,
I'm not sure if this question has arisen before. I would like to create a database that lists our Sub Contractors and enter their contact information as well as when their insurance and/or license expires. Once that is entered is there a way that every day when you open that particular database something pops up with a list of all the subs that have insurances that are expiring so that I can contact them and get the new info before the old info expires?
I hope I explained this correctly?
Thanks,
DV
Creating Notifications
-
- Posts: 3
- Joined: Thu Sep 13, 2018 11:12 pm
Creating Notifications
Open Office 4 Windows 7
-
- Volunteer
- Posts: 1547
- Joined: Wed Jun 24, 2015 12:56 am
- Location: Colorado, USA
Re: Creating Notifications
Yes, SQL has a DATEDIFF function that could be used in a query to give that information. For instance if you had a database table with a DATE field named "ExpDate", then you could add a clause to a query, something likeis there a way that every day when you open that particular database something pops up with a list of all the subs that have insurances that are expiring so that I can contact them and get the new info before the old info expires?
Code: Select all
DATEDIFF( 'day', CURDATE( ), "ExpDate" ) AS "Diff"
Then if you added a WHERE clause to the query, something like
Code: Select all
WHERE "Diff" < 30
To write a complete query requires knowledge of your database table structure.
If your problem has been solved, please edit this topic's initial post and add "[Solved]" to the beginning of the subject line
Apache OpenOffice 4.1.14 & LibreOffice 7.6.2.1 (x86_64) - Windows 10 Professional- Windows 11
Apache OpenOffice 4.1.14 & LibreOffice 7.6.2.1 (x86_64) - Windows 10 Professional- Windows 11