Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New to the CF scene
    Join Date
    Jul 2004
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question How would I make it so that this query would be run every day at midnight?

    How would I make it so that this query would be run every day at midnight:
    UPDATE Users SET Karma = Karma + 1

    thanks in advance for any help
    Last edited by Ricapar9x; 07-12-2004 at 04:37 AM.

  • #2
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,068
    Thanks
    0
    Thanked 256 Times in 252 Posts
    Create a VB application and schedule its execution in the Windows Scheduled Tasks.
    Glenn
    ____________________________________

    My Blog
    Tower of Hanoi Android app (FREE!)
    Tower of Hanoi Leaderboard
    Samegame Facebook App
    vBulletin Plugins
    ____________________________________

  • #3
    New to the CF scene
    Join Date
    Jul 2004
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Unhappy

    That would work if I was hosting my own server. The problem is that im using another free server that supports ASP for hosting.

    Would there be any way to do it through an ASP page?

  • #4
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    There's no way to automatically run an ASP page at a specific time of the day but that shouldn't stop you. Try using a computed field instead. First you need a date for "0 karma", then all you need to is compute the difference between that date and today. The value from that computation will automatically increase by 1 each day.
    Check out the Forum Search. It's the short path to getting great results from this forum.

  • #5
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,068
    Thanks
    0
    Thanked 256 Times in 252 Posts
    You can also run an ASP page in the Scheduled Tasks of your machine. Just choose Internet Explorer and add the URL of asp page in the parameter for IEXPLORE.EXE. See sample below:

    Run: C:\PROGRA~1\INTERN~1\IEXPLORE.EXE "http://myhost.com/myname/autoupdate.asp"

    The problem with that is you need to make your pc available every midnight.
    Last edited by glenngv; 07-13-2004 at 02:21 AM.
    Glenn
    ____________________________________

    My Blog
    Tower of Hanoi Android app (FREE!)
    Tower of Hanoi Leaderboard
    Samegame Facebook App
    vBulletin Plugins
    ____________________________________

  • #6
    New to the CF scene
    Join Date
    Jul 2004
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts
    well, i was able to get it. I used it to make the difference in days between the account creation date and the current date, as someone else said above.

    Thanks for the help!


  •  

    Posting Permissions

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