Loading ...
Sorry, an error occurred while loading the content.

Re: [mugh-sqlcon] clearing deleted tables

Expand Messages
  • Roji. P. Thomas
    Hunter, You done have to *shoot* the tables to clear them from memory. The deleted and inserted tables have scope only in the trigger level. Once you have done
    Message 1 of 3 , Mar 5, 2006
    • 0 Attachment
      Hunter,

      You done have to *shoot* the tables to clear them from memory.

      The deleted and inserted tables have scope only in the trigger level.
      Once you have done with the trigger execution, the tables will be cleared automatically.

      So scenario you are explaining is impossible. You must be doing something else wrong.

      Can you post the code you are using?

      Regards
      Roji. P. Thomas

      ----- Original Message -----
      From: sql hunter
      To: sqlcon@yahoogroups.com
      Sent: Monday, March 06, 2006 12:41 PM
      Subject: [mugh-sqlcon] clearing deleted tables


      Hi All,

      how to clear the *deleted *table from sql server 2000 memory ?

      I require this to set an audit to capture the updates done in the DB.

      I have written an update trigger and i am inserting the values in the audit
      table from the* deleted* and *inserted* tables in memory.

      But everytime i update, the trigger also inserts all the previous updates
      done in the system.

      Please help.

      rgds,
      SQL Hunter


      [Non-text portions of this message have been removed]



      SqlCon is a special interests group run under the aegis of MUGH - http://www.mugh.net
      http://www.mugh.net/sql

      Visit http://www.mugh.net/dnug to join .NET User Group.




      SPONSORED LINKS C programming language Computer programming languages Java programming language
      The c programming language C programming language Concept of programming language


      ------------------------------------------------------------------------------
      YAHOO! GROUPS LINKS

      a.. Visit your group "sqlcon" on the web.

      b.. To unsubscribe from this group, send an email to:
      sqlcon-unsubscribe@yahoogroups.com

      c.. Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.


      ------------------------------------------------------------------------------



      [Non-text portions of this message have been removed]
    • Madhu K Nair
      Hi, As Roji has mentioned, the scenario mentioned is not the actual one. I suppose, for audit trail u have to capture only from deleted table. not from both
      Message 2 of 3 , Mar 6, 2006
      • 0 Attachment
        Hi,

        As Roji has mentioned, the scenario mentioned is not the actual one.
        I suppose, for audit trail u have to capture only from deleted
        table. not from both deleted and inserted.

        --regards

        Madhu

        --- In sqlcon@yahoogroups.com, "Roji. P. Thomas" <thomasroji@...>
        wrote:
        >
        > Hunter,
        >
        > You done have to *shoot* the tables to clear them from memory.
        >
        > The deleted and inserted tables have scope only in the trigger
        level.
        > Once you have done with the trigger execution, the tables will be
        cleared automatically.
        >
        > So scenario you are explaining is impossible. You must be doing
        something else wrong.
        >
        > Can you post the code you are using?
        >
        > Regards
        > Roji. P. Thomas
        >
        > ----- Original Message -----
        > From: sql hunter
        > To: sqlcon@yahoogroups.com
        > Sent: Monday, March 06, 2006 12:41 PM
        > Subject: [mugh-sqlcon] clearing deleted tables
        >
        >
        > Hi All,
        >
        > how to clear the *deleted *table from sql server 2000 memory ?
        >
        > I require this to set an audit to capture the updates done in the
        DB.
        >
        > I have written an update trigger and i am inserting the values in
        the audit
        > table from the* deleted* and *inserted* tables in memory.
        >
        > But everytime i update, the trigger also inserts all the
        previous updates
        > done in the system.
        >
        > Please help.
        >
        > rgds,
        > SQL Hunter
        >
        >
        > [Non-text portions of this message have been removed]
        >
        >
        >
        > SqlCon is a special interests group run under the aegis of MUGH -
        http://www.mugh.net
        > http://www.mugh.net/sql
        >
        > Visit http://www.mugh.net/dnug to join .NET User Group.
        >
        >
        >
        >
        > SPONSORED LINKS C programming language Computer programming
        languages Java programming language
        > The c programming language C programming language Concept
        of programming language
        >
        >
        > --------------------------------------------------------------------
        ----------
        > YAHOO! GROUPS LINKS
        >
        > a.. Visit your group "sqlcon" on the web.
        >
        > b.. To unsubscribe from this group, send an email to:
        > sqlcon-unsubscribe@yahoogroups.com
        >
        > c.. Your use of Yahoo! Groups is subject to the Yahoo! Terms
        of Service.
        >
        >
        > --------------------------------------------------------------------
        ----------
        >
        >
        >
        > [Non-text portions of this message have been removed]
        >
      • sql hunter
        thx madhu for the response ... however this has been resolved now... inserted tables come into picture when u also hav to capture the new values of the
        Message 3 of 3 , Mar 6, 2006
        • 0 Attachment
          thx madhu for the response ...
          however this has been resolved now...

          inserted tables come into picture when u also hav to capture
          the new values of the updates.

          rgds,
          Rahul
          (SQL Hunter)


          On 3/6/06, Madhu K Nair <madhuotp@...> wrote:
          >
          > Hi,
          >
          > As Roji has mentioned, the scenario mentioned is not the actual one.
          > I suppose, for audit trail u have to capture only from deleted
          > table. not from both deleted and inserted.
          >
          > --regards
          >
          > Madhu
          >
          > --- In sqlcon@yahoogroups.com, "Roji. P. Thomas" <thomasroji@...>
          > wrote:
          > >
          > > Hunter,
          > >
          > > You done have to *shoot* the tables to clear them from memory.
          > >
          > > The deleted and inserted tables have scope only in the trigger
          > level.
          > > Once you have done with the trigger execution, the tables will be
          > cleared automatically.
          > >
          > > So scenario you are explaining is impossible. You must be doing
          > something else wrong.
          > >
          > > Can you post the code you are using?
          > >
          > > Regards
          > > Roji. P. Thomas
          > >
          > > ----- Original Message -----
          > > From: sql hunter
          > > To: sqlcon@yahoogroups.com
          > > Sent: Monday, March 06, 2006 12:41 PM
          > > Subject: [mugh-sqlcon] clearing deleted tables
          > >
          > >
          > > Hi All,
          > >
          > > how to clear the *deleted *table from sql server 2000 memory ?
          > >
          > > I require this to set an audit to capture the updates done in the
          > DB.
          > >
          > > I have written an update trigger and i am inserting the values in
          > the audit
          > > table from the* deleted* and *inserted* tables in memory.
          > >
          > > But everytime i update, the trigger also inserts all the
          > previous updates
          > > done in the system.
          > >
          > > Please help.
          > >
          > > rgds,
          > > SQL Hunter
          > >
          > >
          > > [Non-text portions of this message have been removed]
          > >
          > >
          > >
          > > SqlCon is a special interests group run under the aegis of MUGH -
          > http://www.mugh.net
          > > http://www.mugh.net/sql
          > >
          > > Visit http://www.mugh.net/dnug to join .NET User Group.
          > >
          > >
          > >
          > >
          > > SPONSORED LINKS C programming language Computer programming
          > languages Java programming language
          > > The c programming language C programming language Concept
          > of programming language
          > >
          > >
          > > --------------------------------------------------------------------
          > ----------
          > > YAHOO! GROUPS LINKS
          > >
          > > a.. Visit your group "sqlcon" on the web.
          > >
          > > b.. To unsubscribe from this group, send an email to:
          > > sqlcon-unsubscribe@yahoogroups.com
          > >
          > > c.. Your use of Yahoo! Groups is subject to the Yahoo! Terms
          > of Service.
          > >
          > >
          > > --------------------------------------------------------------------
          > ----------
          > >
          > >
          > >
          > > [Non-text portions of this message have been removed]
          > >
          >
          >
          >
          >
          >
          >
          > SqlCon is a special interests group run under the aegis of MUGH -
          > http://www.mugh.net
          > http://www.mugh.net/sql
          >
          > Visit http://www.mugh.net/dnug to join .NET User Group.
          >
          > Yahoo! Groups Links
          >
          >
          >
          >
          >
          >
          >
          >


          [Non-text portions of this message have been removed]
        Your message has been successfully submitted and would be delivered to recipients shortly.