| Author |  | 
      
        | jeffw_00 Super User
 
  
 
 Joined: June 30 2007
 Online Status: Offline
 Posts: 935
 | 
          Hi - I had a macro that trimmed my event log to 15 days once a week.  I just discovered it stopped working back in December 2013(!).  The error it generates is
           | Posted: August 02 2014 at 09:22 | IP Logged |   |  
           | 
 |  
 AN error occurred while trimming the eventlog table.
 SQLSTATE = S1000
 [Sybase][ODBC Driver][Adaptive Server ANywhere]General error: Unable to find in index 'eventlog' for table 'eventlog'
 
 How do I fix? (Still running 2.1.4) if I have to clear the entire log that's cool.
 
 Thanks!
 /j
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Jeff,
           | Posted: August 04 2014 at 19:59 | IP Logged |   |  
           | 
 |  
 Looks like the database (eventlog) is corrupt (probably grew to large).
 
 Since you're on version 2.1.4, I would run the Database upgrade utility and check the option to not migrate eventlog entries. This will rebuild and compact your database and should fix your problem.
 
 An alternative would be to update to version 2.1.5a which will not bring over your eventlog entries (you'll start fresh). Additionally, this version separates out the eventlog into its own database so if it does corrupt or grow too large, it won't affect your other configuration data.
 
 Dave.
 
 | 
       
        | Back to Top |       | 
       
       
        |  | 
        | jeffw_00 Super User
 
  
 
 Joined: June 30 2007
 Online Status: Offline
 Posts: 935
 | 
          Hi Dave - Thanks!  No offense, but I'm going to let others bolder than me beta 2.1.5 for a bit (I'm flat out at work so I just need things to run). Sounds like one option is to do nothing until I upgrade, but - if i ran the Database upgrade utility (after making a copy of my PH folder, of course), I don't mean to be dim, but what is the exact command?   Do I just double-click on phupg.exe in the powerhome (2.1.4) folder?
           | Posted: August 04 2014 at 20:14 | IP Logged |   |  
           | 
 |  
 Thanks!
 /j
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | BeachBum Super User
 
  
  
 Joined: April 11 2007
 Location: United States
 Online Status: Offline
 Posts: 1880
 | 
          Jeff, quick answer is yes. That should fix it.
           | Posted: August 04 2014 at 20:42 | IP Logged |   |  
           | 
 |  
 __________________
 Pete - X10 Oldie
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | jeffw_00 Super User
 
  
 
 Joined: June 30 2007
 Online Status: Offline
 Posts: 935
 | 
          ok.  thx.  will try it soon
           | Posted: August 04 2014 at 20:53 | IP Logged |   |  
           | 
 |  /j
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | jeffw_00 Super User
 
  
 
 Joined: June 30 2007
 Online Status: Offline
 Posts: 935
 | 
          fixed it -thanks!
           | Posted: August 08 2014 at 11:44 | IP Logged |   |  
           | 
 |  | 
       
        | Back to Top |     | 
       
       
        |  | 
        | RichardL Senior Member
 
  
 
 Joined: December 29 2008
 Location: United States
 Online Status: Offline
 Posts: 165
 | 
          I trim my Event log nightly, so all has been well.  Was doing some maintenance and disabled the timed event to trim the log, then forgot to re-enable it.  So...now my PHLogs.DB is 177MB.
           | Posted: August 12 2016 at 16:50 | IP Logged |   |  
           | 
 |  
 I ran PHUpg.exe, saw it run by many tables, and it rebuilt my pwrhome.db file from 4MB to 3MB, good, but my PHLogs.DB is still 177MB.
 
 I tried to delete it and when I start PH I get challenged with a login for the database, which I do not know.  Even if I go around that, PH does not start.  Put the PHLogs.db file back for now.
 
 Any way to shrink the PHLogs.DB file?
 
 Thank you.
 
 Richard
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Richard,
           | Posted: August 12 2016 at 18:54 | IP Logged |   |  
           | 
 |  
 You're on the right track. Go ahead and delete the
 phlogs.db file and then copy the phlogs10.db (in the
 same directory) to phlogs.db.
 
 The phlogs10.db is just an empty logs file for just this
 type of situation
  . 
 Dave.
 
 | 
       
        | Back to Top |       | 
       
       
        |  | 
        | RichardL Senior Member
 
  
 
 Joined: December 29 2008
 Location: United States
 Online Status: Offline
 Posts: 165
 | 
          Beautiful!  That worked fine.
           | Posted: August 13 2016 at 09:31 | IP Logged |   |  
           | 
 |  
 Thanks so much for the quick reply.
   | 
       
        | Back to Top |     | 
       
       
        |  |