www.webdeveloper.com
Results 1 to 5 of 5

Thread: MOD Alternative

  1. #1
    Join Date
    Jun 2004
    Location
    Kansas City, MO
    Posts
    1,607

    MOD Alternative

    Im looking for a MOD like Function.
    You may be able to help me come up w/ a different solution
    What i need to do is send a email reminder every 24 hours its overdue. This could continue for weeks but most likely it will be taken care of w/ the first reminder.

    What i have so far and it works but i need it to be more flexable.
    Code:
    Select dateDiff("Hour", Date_Created, CURRENT_TIMESTAMP) as TotalTime
    From Requests
    WHERE dateDiff("Hour", Date_Created, CURRENT_TIMESTAMP) = 24
    w/ out typing
    Code:
    WHERE dateDiff("Hour", Date_Created, CURRENT_TIMESTAMP) = 24
    AND dateDiff("Hour", Date_Created, CURRENT_TIMESTAMP) = 48
    AND dateDiff("Hour", Date_Created, CURRENT_TIMESTAMP) = 96, etc...

  2. #2
    Join Date
    Aug 2005
    Location
    The Garden State
    Posts
    5,634
    MySQL does have a mod operator, yanno.

    http://dev.mysql.com/doc/refman/4.1/...recedence.html

  3. #3
    Join Date
    Jun 2004
    Location
    Kansas City, MO
    Posts
    1,607
    Which would come in handy if i was using mySQL.

    Im using SQL Server.

  4. #4
    Join Date
    Aug 2005
    Location
    The Garden State
    Posts
    5,634
    sorry, your syntax was similar to mysql

    m$ says sql server supports %


    http://www.microsoft.com/technet/pro.../75517c11.mspx

  5. #5
    Join Date
    Jun 2004
    Location
    Kansas City, MO
    Posts
    1,607
    Thats what i was looking for. Thanks.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles