Results 1 to 3 of 3
  1. #1
    New Lounger
    Join Date
    Nov 2002
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Share data between records (97-SR2)

    I have a question I don't seem to be able to do. I am working with database that calculates meter readings, and I would like to be able to have a field look at the ending meter reading from the last entry and use it as the beginning reading for the current record. Is there an easy way to do this? Would it be possible to do this with multiple machines in one table or would each machine need its own table? I am currently using a combo box to lookup the device from a master table ([tblDevice]).

  2. #2
    3 Star Lounger
    Join Date
    Dec 2000
    Location
    USA
    Posts
    379
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Share data between records (97-SR2)

    I had a similar need - all the truck mileage readings were kept in one table.
    Take a look at this thread: <A target="_blank" HREF=http://www.wopr.com/cgi-bin/w3t/showthreaded.pl?Cat=&Board=acc&Number=30307&page=& view=&sb=&o=&vc=1#Post30307>previous thread</A>
    In my case I needed both readings to perform a calculation; in your case the MovePrevious reading could be written to the new record.

  3. #3
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts

    Re: Share data between records (97-SR2)

    As soon as the machine # was entered in a new record, you could do a DMax("OdometerReading","tblReadings","machineid=" & txtmachineid) to get the last Odometer reading from the table for a specific machine.
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

Posting Permissions

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