Results 1 to 4 of 4
  1. #1
    Join Date
    Oct 2004

    Unanswered: Tracking changes

    I have a database that is updated a couple of times daily from a web script. The Database is of NBA stats. I was wondering if it is possible to know how much the statistics have changed from the last update.
    The whole database is re-written each time.


  2. #2
    Join Date
    Mar 2003
    The Bottom of The Barrel
    Provided Answers: 1
    Not if the whole database is re-written.

    Might I suggest NOT scrubbing the database each time you import? It would seem that for sports stats it would be nice to be able to see trends no?
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

  3. #3
    Join Date
    Oct 2004
    Thank you for the reply
    Yes I would like to see the trends.
    I am not sure how I can go about having the script retain the old db. Maybe if I have the script rename the old file?

  4. #4
    Join Date
    Dec 2002
    Préverenges, Switzerland
    one possibility:

    import your data into a "temporary" table (actually not temporary, but one where the data is replaced with each new update -- i.e. exactly what you have today).

    copy the structure of your "temporary" table to tblNBAstats

    make a new table:
    dtCycle, date, PK, default = Now()

    add a field to the definition of tblNBAstats:
    dtCycle, date, FK on tblCycle.dtCycle

    when you have new data, append a new record in tblCycle and capture the dtCycle of the new record in tblCycle.

    now append your new data plus the captured dtCycle into tblNBAstats.

    from there:

    SELECT * FROM tblNBAstats WHERE dtCycle = " & Dmax("dtCycle", "tblCycle") & ";"
    gets you the latest stuff you imported -- exactly as you are seeing it today...

    ...but tblNBAstats now also retains the old stats with an update-date so you can play with the history.

    currently using SS 2008R2

Posting Permissions

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