1 Reply Latest reply on Feb 15, 2013 4:27 PM by alexn

    Deleting events from SQL Logs based on Host names+date

      Hello,

      I would like to delete SQL Logs based on host names in my enterprise. I am using EPO 4.6 where one of the PC has introduced around a million events in the database on particular three days until it was re-imaged. does any one know a quick SQL query and the steps to execute that  that i can run on SQL server 2005 against my EPO database to delete events based on Node or object name( pc name ) and on certain date. Database is getting huge day by day. EPO is on Server 2003

      Thanks a ton for your help.

        • 1. Re: Deleting events from SQL Logs based on Host names+date
          alexn

          Hi,

           

          I can only help you with specific dates only,

           

          Purge events from the database.
          All events older than the specified date will be removed from the database. For example, if reporting information for the last three months is required, then specify a date three months in the past.

          1. Type the command below at the 1> prompt and press ENTER:

            delete from EPOEvents where DetectedUTC < 'YYYY-MM-DD'

            Ensure that the format of the date is year-month-day. Example: 2007-12-01 for December 1, 2007.

          2. At the 2>  prompt, type go and press ENTER.
            NOTE: This command can take more than an hour to complete, depending on the number of events to purge. If this completes successfully, you see a message indicating the number of affected rows

          May be some one else would jumpin and give you required command .

           

          Thank you.