Martin
Wed 12th Jul '00, 8:26pm
okay, here's a toughie (at least for me)
As some of you know, I had a HUGE crash a few weeks ago that crashed my database and cost me 100k+ posts and sent my users into a frenzy.
Anyway, after puring thru all the files by hand, I finally got rid of all the corrupted data and have a functioning database again.
This is where my problem lies:
I want to combine the old post and thread data with the new. the easiest way to do that, as I see it, would be to do a dump on the existing (new) databases and import it into the old.
The problem is, we started a gain from scratch, so I will have duplicate threadids and postids.
Is there a query I can run to add a number to the threadid columns in the thread and post tables and the postid column in the post table?
Say I had 2500 threads and 25000 posts I needed to renumber. How would I go about that? PLease tell me there's a simple query I can run?
Second, mysqlimport seems to be importing the data okay (I've been playing with it) but it doesn't show up in the program. All I can see is the data that was there before the import, none of the imported data is showing, though the files do increase proportionately in size. Am I doing something wrong?
I'm running it like this:
mysqlimport -r temp post.sql
mysqlimport -r temp thread.sql
As some of you know, I had a HUGE crash a few weeks ago that crashed my database and cost me 100k+ posts and sent my users into a frenzy.
Anyway, after puring thru all the files by hand, I finally got rid of all the corrupted data and have a functioning database again.
This is where my problem lies:
I want to combine the old post and thread data with the new. the easiest way to do that, as I see it, would be to do a dump on the existing (new) databases and import it into the old.
The problem is, we started a gain from scratch, so I will have duplicate threadids and postids.
Is there a query I can run to add a number to the threadid columns in the thread and post tables and the postid column in the post table?
Say I had 2500 threads and 25000 posts I needed to renumber. How would I go about that? PLease tell me there's a simple query I can run?
Second, mysqlimport seems to be importing the data okay (I've been playing with it) but it doesn't show up in the program. All I can see is the data that was there before the import, none of the imported data is showing, though the files do increase proportionately in size. Am I doing something wrong?
I'm running it like this:
mysqlimport -r temp post.sql
mysqlimport -r temp thread.sql