Prosper202 DB needs cleaning - Help

Mike

New member
Jun 27, 2006
6,777
116
0
51
On the firing line
Okay, so I've got a couple different installs of Prosper202 and it seems like once they hit the 200,000 click mark (225,000-ish) it becomes much less reliable in the data it provides.

Let me explain:

When the install is fresh, I can upload reports and get subids to match spot on. The more data in the DB, the less accurate the subids match.

So, what I want to do it do a dump while it's still receiving clicks.

Can this be done without fucking things up completely?

I thought about just dumping all the click tables, but since I have live campaigns, I'm concerned about it messing up the links, etc.

Thoughts? Has anyone tried this? Results?

"Talk to me Goose."

/edit/

Also, would it be possible to setup a Cron job to automatically dump the necessary tables periodically?
 


Good question, I'm also wondering if anyone has some info on this.
 
never tried this, i don't know for certain if it'll break prosper (pretty sure it won't?), but if i were gonna try this on a live server, rather than doing DROP TABLE (which will cause you to lose clicks while you recreate the table, unless you decide to make it transactional, which is still kind of ugly), you should delete small chunks one bit at a time.

i'd write a [python/php] wrapper to do the following pseudocode--
Code:
# don't delete today's clicks, they might be converting right now!
q = "DELETE FROM clicks WHERE date <= TODAY() LIMIT 50"
while true:
  result = mysql_query(q)
  if not result.rows_affected() > 0:
     break
  # don't crash a live server!
  while system.load > 0.75:  time.sleep(1)