2005-06-05, 04:55 PM
Sub, I'd like the ability to import data into the DB. Specifically, if I need to do a fresh install, like I did the other week, I'd like some method to import all of the shows, that I recorded previously, back into the DB so they show up in the recordings area and I can watch and delete the shows from my MVP's. (Features which are unavailable through the Video Library) Not to mention, having the attached show information back is really required to make head or tails of all of the .MPG files.
Obviously you'd need an export method to make this work, but this would really make upgrading and fresh reinstalls much more painless.
Perhaps dumping the existing recordings and scheduled recording data to an .XML file?
I managed to do this manually with the following process, which sucks but it at least my stuff is back:
***Stop the GBPVR Service and make backups before doing this.***
1. In the OLD db, create a query, switch to SQL view and paste this code:
2. Run the query, select all of the rows, CTRL-C to copy
3. Open the PROGRAMME table in the NEW database
4. Paste the records into the table
5. Select only all of the values in the OID column, these are autonumbered so they will have changed from what you pasted earlier.
6. Keep them selected, do not copy them yet.
7. Switch back to the OLD db.
8. In the OLD db, create a query, switch to SQL view and paste this code:
9. Run the query
10. Go back to the NEW db, copy (CTRL-C) the values you selected above.
11. Switch back to the OLD db
12. Open the newly created table
13. Select the PROGRAMME_OID column
14. Paste the new values
15. Select all of the rows, CTRL-C to copy
16. Switch to the DB, open the RECORDING_SCHEDULE table
17. If you've done everything correctly, CTRL-V to paste the records, and you're done.
Start the GBPVR service, voila.
I have duplicate recording_group values, but this has no immediate impact. Sub can you comment on that?
Obviously you'd need an export method to make this work, but this would really make upgrading and fresh reinstalls much more painless.
Perhaps dumping the existing recordings and scheduled recording data to an .XML file?
I managed to do this manually with the following process, which sucks but it at least my stuff is back:
***Stop the GBPVR Service and make backups before doing this.***
1. In the OLD db, create a query, switch to SQL view and paste this code:
Code:
SELECT PROGRAMME.*
FROM PROGRAMME INNER JOIN RECORDING_SCHEDULE ON PROGRAMME.oid = RECORDING_SCHEDULE.programme_oid
WHERE (((RECORDING_SCHEDULE.recording_type)=0) AND ((RECORDING_SCHEDULE.status)=2));
2. Run the query, select all of the rows, CTRL-C to copy
3. Open the PROGRAMME table in the NEW database
4. Paste the records into the table
5. Select only all of the values in the OID column, these are autonumbered so they will have changed from what you pasted earlier.
6. Keep them selected, do not copy them yet.
7. Switch back to the OLD db.
8. In the OLD db, create a query, switch to SQL view and paste this code:
Code:
SELECT * INTO MY_OLD_RECS
FROM RECORDING_SCHEDULE
WHERE (((RECORDING_SCHEDULE.status)=2) AND ((RECORDING_SCHEDULE.recording_type)=0));
9. Run the query
10. Go back to the NEW db, copy (CTRL-C) the values you selected above.
11. Switch back to the OLD db
12. Open the newly created table
13. Select the PROGRAMME_OID column
14. Paste the new values
15. Select all of the rows, CTRL-C to copy
16. Switch to the DB, open the RECORDING_SCHEDULE table
17. If you've done everything correctly, CTRL-V to paste the records, and you're done.
Start the GBPVR service, voila.
I have duplicate recording_group values, but this has no immediate impact. Sub can you comment on that?