Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Database & SysAdmin
  3. Database
  4. How to find out when or who updated my Database.

How to find out when or who updated my Database.

Scheduled Pinned Locked Moved Database
csharpasp-netdatabasetutorialannouncement
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • E Offline
    E Offline
    Eyungwah
    wrote on last edited by
    #1

    Hello: Could someone point me to the right track..I have creat ASP.NET in VS2005 web site that ppl will log in and If the user update the Database I would like it to display that user name on the page. Thanks, Eyungwah.

    M 1 Reply Last reply
    0
    • E Eyungwah

      Hello: Could someone point me to the right track..I have creat ASP.NET in VS2005 web site that ppl will log in and If the user update the Database I would like it to display that user name on the page. Thanks, Eyungwah.

      M Offline
      M Offline
      Mattias Olgerfelt
      wrote on last edited by
      #2

      The most common way of doing this is to use triggers on the table you want to check for changes in, and then save date and username in an other table. You can also add two fields, last modifiedBy and lastModifiedTime to each table you want to check for changes in, in addition you add a trigger and copies these values to an other table eg: TableNameLog if the original table was named TableName. If you do not wan to use triggers you have to save the information in two places when a save occurs. You can use client-code or storede procedrues in the database. /M

      E 1 Reply Last reply
      0
      • M Mattias Olgerfelt

        The most common way of doing this is to use triggers on the table you want to check for changes in, and then save date and username in an other table. You can also add two fields, last modifiedBy and lastModifiedTime to each table you want to check for changes in, in addition you add a trigger and copies these values to an other table eg: TableNameLog if the original table was named TableName. If you do not wan to use triggers you have to save the information in two places when a save occurs. You can use client-code or storede procedrues in the database. /M

        E Offline
        E Offline
        Eyungwah
        wrote on last edited by
        #3

        Thank you Mattias for your replied. I have a Login.aspx page. On my default.aspx page which is contained Database Table. I was wondering if you could please give me some sample code. I wanted to add "Last Modified By" field table and if the Logged in user update the table then have his/her name display under that "Last Modified By". Thanks again for your help. Eyungwah

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups