Update a Table Field Whenever the Record is Changed using a Data Macro in Microsoft Access

แชร์
ฝัง
  • เผยแพร่เมื่อ 5 ก.ย. 2024
  • In this Microsoft Access tutorial, I will teach you how to update the date that a record was last updated using a data macro. This runs at the table level. Use them sparingly, but they can be useful.
    LEARN MORE:
    599cd.com/Data...
    PRE-REQUISITES:
    Access Advanced 1: 599cd.com/ACA1
    RECOMMENDED COURSES:
    Access Advanced 6: 599cd.com/ACA6
    BECOME A MEMBER:
    TH-cam: / @599cd
    or My Site: 599cd.com/THMe...
    ADDITIONAL RESOURCES:
    FREE Access Beginner Level 1: 599cd.com/Free1
    $1 Access Level 2: 599cd.com/1Dollar
    Donate to my Tip Jar: 599cd.com/TipJar
    Get on my Mailing List: 599cd.com/YTML
    Contact Me: 599cd.com/Contact
    TechHelp: 599cd.com/Tech...
    Consulting Help: 599cd.com/DevNet
    Twitter: / learningaccess
    en.wikipedia.o...
    products.offic...
    microsoft.com/...
    KEYWORDS
    access 2016, access 2019, access 2021, access 365, microsoft access, ms access, ms access tutorial, #msaccess, #microsoftaccess, #help, #howto, #tutorial, #learn, #lesson, #training, #database, #fasttips, data macro, last updated, trigger, before change, update date when record changed
    QUESTIONS:
    Please feel free to post your questions or comments below. Thanks.

ความคิดเห็น • 24

  • @Nutflash1978
    @Nutflash1978 ปีที่แล้ว +7

    Best access teacher period.

    • @599CD
      @599CD  ปีที่แล้ว +1

      Thanks

  • @johnpap9328
    @johnpap9328 4 หลายเดือนก่อน

    That was perfect. Exactly what i was looking for. Thank you!

  • @Jojosmith342
    @Jojosmith342 ปีที่แล้ว +2

    Great teacher as all time Richard. Thanks a lot for your valuable lesson

    • @599CD
      @599CD  ปีที่แล้ว +1

      My pleasure!

  • @christophermatthews555
    @christophermatthews555 5 หลายเดือนก่อน

    I went a step beyond this by creating a macro to track when a particular field in a table has changed. I created a child table to record the date the change was made to the field and to record the old field value. This worked fine for a while but my parent table eventually became corrupted. The fields that I was tracking changings too in the parent table were getting corrupted with special characters and different language characters. I disabled the macros and had to replace the parent table from backup data. I'm not 100% sure the macros were to blame but I haven't had any further corruption of data since. I had no idea that table level macros were so risky. Thanks for pointing that out in the video.

  • @ssdusd
    @ssdusd ปีที่แล้ว +2

    If you have split database, Where should it be placed? FE BE? Or both are work?

    • @cruzinsweetsntreats
      @cruzinsweetsntreats ปีที่แล้ว

      When splitting your database, you can keep the backend in the same folder as the front end, if it's not a security risk for your needs.
      Though, best practice, for security, would be to save that backend in a separate folder, which could be a different drive, from the main front end. That drive, if accessed by more than 1 person, be the same to keep the flow of data, with less risk of corruption.

    • @599CD
      @599CD  ปีที่แล้ว +3

      BE on a shared server folder. Unique FE copy on each workstation.

  • @Jojosmith342
    @Jojosmith342 ปีที่แล้ว

    all thumbs up for the valuable lessons as always. Thanks a lot Richard for your hard work 👍

    • @599CD
      @599CD  ปีที่แล้ว

      Welcome

  • @garrettmichael3616
    @garrettmichael3616 ปีที่แล้ว

    Thank you, I’m such a fan of your videos! Does this work with a split fe be? If so, do we do the macro on the be?

    • @599CD
      @599CD  ปีที่แล้ว +2

      Data macros are stored in the table, so put them wherever the table is located.

    • @599CD
      @599CD  ปีที่แล้ว +1

      Try it Yourself: 599cd.com/Try

  • @kamleshjain6872
    @kamleshjain6872 ปีที่แล้ว

    Lovely.... Never knew such things exist

    • @599CD
      @599CD  ปีที่แล้ว

      Glad you like

  • @luzkrg
    @luzkrg ปีที่แล้ว

    Awesome!!! 🤩 Wonder if it’ll work with an Environ(“Username”)

    • @599CD
      @599CD  ปีที่แล้ว

      Not sure. Give it a try.

  • @tajuddinidrisi6610
    @tajuddinidrisi6610 ปีที่แล้ว

    thanks

    • @599CD
      @599CD  ปีที่แล้ว

      welcome

  •  ปีที่แล้ว

    The "LastUpdated" field is also filled with the current date and time when the record is created (= not changed). How to solve this?

    • @599CD
      @599CD  ปีที่แล้ว

      599cd.com/ASK

  • @khalidalanazi1387
    @khalidalanazi1387 ปีที่แล้ว

    How I can save the attachment on shared folder on the access

    • @599CD
      @599CD  ปีที่แล้ว

      599cd.com/Ask