Multiple Q&S Libraries and Synching Tag & Title Rules
@Q&S Users:
If you have and want only a single Q&S database (99% chance), you can quit reading this post.
I have 4 "real" Q&S Libraries that I like to keep in synch for Tag Rules, Tag Priorities, and Title Rules so I have an absolute minimum of table maintenance to do. Yes, you can have multiple Q&S libraries, as long as you name them properly, and create each of them from the "official" Q&S library downloaded from the Q&S original post's .jar(.zip) file. You have to upgrade their databases individually whenever Q&S has a new version, of course.
The 4 Libraries are:
1. QuarantineAndScrub_filter
2. QuarantineAndScrub_prescrub
3. QuarantineAndScrub
4. QuarantineAndScrub_postscrub
Plus 2 Pristine Libraries:
5. CalibreEnglish
6. CalibreSpanish (I taught myself to read Spanish)
#1 is the very first Library that new ebooks are added into. Duplicates across all of the libraries are deleted here. I also may decide I don't really need another "History of Napolean's Early Years" or whatever, and delete it. I don't keep books here for long. I either delete them or move them to #2.
#2 is where they are converted to epub, their tags get a preliminary scrubbing, their ISBNs are extracted, their Authors and Author Initials are standardized, and then they are held indefinitely until I want to work on them. They are then moved to #3.
#3 is my main Q&S library. I only add books for scrubbing in small numbers so that jobs that are "for all books" or "all series" don't take long. When fully scrubbed, I move them to #4.
#4 is where they are held for any final minor fixes and perhaps a final Tag Scrubbing based on new Rules created after they left #3, but mainly to get them out of #3 so #3 does not have a lot of books in it at any one time. Ratings are downloaded here if needed. This is also where a full "Modify Epub" is run on all of them, plus Count Pages and Derive Genres. A final small Modify Epub is run to do a final metadata embed plus update their jackets. They may stay in #4 indefinitely based on whether I wish to work on them sooner or later. They are then moved from #4 to #5 or #6 depending on their language.
Okay, back to the reason for this post. How do I keep the Q&S Rules in synch to obviate the need to update the various Q&S Rules tables multiple times? Easily.
Step #1. Open DB Browser for SQLite.
Step #2. Open Library #3 (my primary Q&S library)
Step #3. Attach Libraries #2 and #4 using the Attach menu option. Assume that the "name" I choose for #2 is QS2, and for #4 is QS4.
Step #4. Switch to the SQL Tab, and copy in the following SQL that is kept in a .txt file for instant access:
INSERT OR REPLACE INTO QS2._tag_priorities SELECT * FROM main._tag_priorities;
INSERT OR REPLACE INTO QS2._tag_rules SELECT * FROM main._tag_rules;
INSERT OR REPLACE INTO QS2._title_rules SELECT * FROM main._title_rules;
INSERT OR REPLACE INTO QS2._global_web_author_series SELECT * FROM main._global_web_author_series;
INSERT OR REPLACE INTO QS2._global_web_series_detail SELECT * FROM main._global_web_series_detail;
INSERT OR REPLACE INTO QS4._tag_priorities SELECT * FROM main._tag_priorities;
INSERT OR REPLACE INTO QS4._tag_rules SELECT * FROM main._tag_rules;
INSERT OR REPLACE INTO QS4._title_rules SELECT * FROM main._title_rules;
INSERT OR REPLACE INTO QS4._global_web_author_series SELECT * FROM main._global_web_author_series;
INSERT OR REPLACE INTO QS4._global_web_series_detail SELECT * FROM main._global_web_series_detail;
Step #5. Execute the SQL by clicking the "forward" button.
Step #6. Write Changes by clicking the "Write Changes" button.
Step #7. Close the database. Exit DB Browser for SQLite.
Done.
Now I can scrub in libraries #2 and #4 and achieve the identical results that I get in #3 (my master Q&S library database with my latest and best Rules). This scenario assumes that Web Source Validation of Work Series is performed mostly in #3, and the historical Web Source validation data is desired in #2 and #4 as well.
DaltonST
Last edited by DaltonST; 12-10-2014 at 02:49 PM.
Reason: Added Additional Q&S Tables to Keep In Synch Across Libraries
|