locked
How to handle schedule in SQL Server RRS feed

  • Question

  • Hi All,

    My application having schedule functionality. Below are possible scenario..

    1. Visit a place every 5 days from 01-Jan-2015 to 31-Dec-2015

    2. Visit a place daily from 01-Jan-2015 to 30-Jun-2015

    3. Visit a place weekly 3 days (Monday. Wednesday and Friday) from 01-Jan-2015 to 30-Sep-2015

    4. Visit a place monthly on Monday and Wednesday from 01-Jan-2015 to 30-Sep-2015

    How to design tables for the above? and do i really need to store all events. Is there any other better method to achieve this in SQL Server?

    Thanks 

    Ganesh S

    Friday, May 8, 2015 7:51 AM

Answers

  • I do want to recommend you SQL Server job scheduling architecture; I have replicated that but that is bit too complex to implement. So, I would rather suggest you to have db structure like below

    Assuming that you are storing event information per user. So, one user can have multiple visit type means unique row for user per event.

    Hope this will help


    Glad to help! Please remember to accept the answer if you found it helpful. It will be useful for future readers having same issue.


    My Profile on Microsoft ASP.NET

    • Proposed as answer by Uri DimantMVP Friday, May 8, 2015 4:13 PM
    • Marked as answer by Charlie Liao Monday, May 18, 2015 8:49 AM
    Friday, May 8, 2015 9:19 AM