View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 3 posts ] 
Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Thu Jul 12, 2007 3:28 pm 
Offline
Joined: Fri Nov 25, 2005 10:22 pm
Posts: 73
Problem: I did a clean install so the database no longer knows what episodes / shows I've already seen.

I still have my old sql file. Can someone tell me (or point me to) how to merge in the "shows already seen" table into my current database?

I have no idea how to use mysql. I have no idea what the name of the table that stores the already seen shows is called.

I can't revert to the old database because pretty much everything has changed in this new install (new tuners, new channels, and a buncha shows already recorded now.)

Thanks!

SeanO

_________________
Dragon 1.0 +
MSI K8N Neo4 Platinum
Corsair 2GB PC3200 400MHz DDR DIMM
AMD Athlon 64 3200+
Plextor PX-716A
WD3200SB
2 x pcHDTV HD-3000
1 x PVR 150
ASUS Extreme N6200TC256/TD
Chaintech AV-710
Nexus NX-4090
Silverstone LC-10


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 13, 2007 1:40 am 
Offline
Joined: Mon Jun 21, 2004 5:28 am
Posts: 700
Location: Germany
I'm sure there is a more elegant way to do this, but there's always the brute force method...

1. Record (or maybe just watch is enough... not sure) with a title that you can search for in the DB. I.e. Something with words in the title that are not likely to appear too often in the DB.

2. Back up the DB. Back up the Backup of the DB (there is a good chance this will take a few tries).

3. Edit the .sql backup file. Search for the title you just recorded. It might appear a few times, but eventually you should find a table that is obviously "already seen" shows.

4. Edit the old .sql backup with the shows you've seen. Search for the table name. Delete everything except this table. Save it to a new file.

5. Edit the new backup. Delete the table, then insert the table from the file you just created.

6. Restore the backup. If you see any unusual errors, go back to step 2.

When your only tool is a hammer.... everything starts to look like a nail.

_________________
ASUS AT3N7A-I (Atom 330)
TBS 8922 PCI (DVB-S2)


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 13, 2007 6:13 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
The table is "oldrecorded".

Use sed or grep to extract the records from your old backup and pipe the results into mysql. This can all be done in one shell command pipeline. Searching for a posting by me that mentions "gzip" or "bzip2" along with "sed" and "mysql" should turn up more detailed directions. They may even be in an obvious place like the backup/restore sticky thread. Since I don't remember this exact request coming up before you'll need to change the table name in the example, but that's easy.


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 


All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 20 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu