Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 12-02-2010, 08:02 AM   #16
atjnjk
Zealot
atjnjk will become famous soon enoughatjnjk will become famous soon enoughatjnjk will become famous soon enoughatjnjk will become famous soon enoughatjnjk will become famous soon enoughatjnjk will become famous soon enough
 
Posts: 107
Karma: 554
Join Date: Oct 2008
Device: none
Quote:
Originally Posted by Lady Fitzgerald View Post
Ouch. I only have 465 existing authors. There has to be an easier way.
[Note: I didn't test this with an actual library as I use FN LN, so it's best to backup your library. This only works if you didn't recalculate author sort after tweaking.]
After doing the tweak thing (see kiwidude's first post):
-Select all books contain authors you wanted to change from 'FN LN' to 'LN, FN'
-Choose 'Edit metadata in bulk' > 'Search and replace' tab
-Search field: author_sort > Search mode: regular expression > Destination field: authors > Mode: replace field > OK

Last edited by atjnjk; 12-02-2010 at 08:11 AM.
atjnjk is offline   Reply With Quote
Old 12-02-2010, 08:20 AM   #17
jackie_w
Grand Sorcerer
jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.
 
Posts: 6,212
Karma: 16534894
Join Date: Sep 2009
Location: UK
Device: Kobo: KA1, ClaraHD, Forma, Libra2, Clara2E. PocketBook: TouchHD3
Might I ask a question re: author_sort? I am happy with my current calibre settings and tweaks (authors is FN LN, author_sort is LN, FN).

However, I occasionally find a book which has author_sort set incorrectly, presumably because I didn't check it well enough as I added it.

So far, if I want to find all my existing anomalies, I have been creating a Catalog of all books in CSV format and using Excel to identify the culprits.

I was wondering, with all the recent developments, whether there is now some kind of regex search I could run to identify them instead. As there are only ever likely to be a handful, I do not need to correct them automatically.

I suspect that I could use Manage Authors to automatically reset the whole library but I'm afraid (possibly groundless) that using a sledgehammer to crack a nut may unfix more than it fixes.

As my regex ability is rather basic at present (far worse than my Excel ability), any suggestions would be welcome.
jackie_w is offline   Reply With Quote
Advert
Old 12-02-2010, 09:05 AM   #18
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,742
Karma: 6997045
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by jackie_w View Post
Might I ask a question re: author_sort? I am happy with my current calibre settings and tweaks (authors is FN LN, author_sort is LN, FN).
...
I was wondering, with all the recent developments, whether there is now some kind of regex search I could run to identify them instead. As there are only ever likely to be a handful, I do not need to correct them automatically.
How do you visually identify them? Are they missing a comma (we can test for that), or do they look wrong (can't test for that).

Searching on author_sort will be supported in the next release (I didn't realize we didn't already have it). Once that happens, you can find all author_sort values that don't have commas using
Code:
not author_sort:~,
(or for completeness)
author_sort:~^[^,]*$
Note that the current release can search author_sort values if you make a composite column containing {author_sort}.
chaley is offline   Reply With Quote
Old 12-02-2010, 09:28 AM   #19
jackie_w
Grand Sorcerer
jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.
 
Posts: 6,212
Karma: 16534894
Join Date: Sep 2009
Location: UK
Device: Kobo: KA1, ClaraHD, Forma, Libra2, Clara2E. PocketBook: TouchHD3
Quote:
Originally Posted by chaley View Post
How do you visually identify them? Are they missing a comma (we can test for that), or do they look wrong (can't test for that).
Thanks for quick reply...

I'm afraid it's the latter -- "looks wrong". It could be anything. It's not anything Calibre has done, I think the data is wrong in the original source and I fail to spot it as I import it.

The kind of search I had in mind was selecting all books where {author_sort} is not equal to LN, FN as derived from the existing {authors} field. I don't believe I have any errors in the {authors} field.

I have already added an author_sort column. Over the weeks, I've even spotted a few of the "wrong 'uns" using the trusty eyeball method because of this added column. I'm looking for something a little more scientific

[Edit: I've just run your suggested "no comma" search which has found 11 errors. So thanks for that, it was definitely a good start]

Last edited by jackie_w; 12-02-2010 at 09:35 AM. Reason: update with search results
jackie_w is offline   Reply With Quote
Old 12-02-2010, 10:08 PM   #20
lvovsky
Member
lvovsky began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Aug 2010
Device: ipad, kindle
I'm an idiot. I ment to ask : is there a way to make the view 'LN, FN'?

Quote:
Originally Posted by lvovsky View Post
In my library, the authors are sorted by 'LN, FN' but the view in Calibre is 'FN LN'. Is there a way to make the view 'FN LN'?
lvovsky is offline   Reply With Quote
Advert
Old 12-02-2010, 10:13 PM   #21
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,742
Karma: 6997045
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by lvovsky View Post
I'm an idiot. I ment to ask : is there a way to make the view 'LN, FN'?
That is the question that Lady Fitz asked in the original post, and what this thread has been about.

She asked how to (easily) change the authors from FN LN to LN, FN. Are you asking a different question?
chaley is offline   Reply With Quote
Old 12-02-2010, 10:34 PM   #22
lvovsky
Member
lvovsky began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Aug 2010
Device: ipad, kindle
Chaley, yes, kind of. Lady Fitz asked about listing and sorting - I'm interested in listing only; my sorting seems to be fine since I took care of it during the import.

For example, my current sort and view (listing) is:

Mikhail Bulgakov
William S. Burroughs

I'd like to (occasionally) have the library and left side author view show:

Bulgakov, Mikhail
Burroughs, William S.

.. and be able to switch the view option back and forth quickly (I don't think 'recalculated authors' is what I'm after)... and it's really "would like to have" enhancements rather than "must have" feature.

Last edited by lvovsky; 12-02-2010 at 10:43 PM.
lvovsky is offline   Reply With Quote
Old 12-02-2010, 10:41 PM   #23
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,742
Karma: 6997045
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
If I understand you correctly, you want your authors to remain in calibre's database as FN LN, but you want to *see* LN, FN on the library view?

If I have this right, then create a new custom column named whatever you want. Give it the type 'column built from other columns', and put {author_sort} into the template box. You will now have a column on the library view showing LN, FN (or whatever is in author_sort)
chaley is offline   Reply With Quote
Old 12-02-2010, 10:51 PM   #24
lvovsky
Member
lvovsky began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Aug 2010
Device: ipad, kindle
chaley, you got it exactly right (i was editing my post with clarification while you posted you answer) AND your solution is right on the money! thank you!

and now it makes sense what jackie_w was saying about added column...

Last edited by lvovsky; 12-02-2010 at 10:55 PM.
lvovsky is offline   Reply With Quote
Old 12-03-2010, 03:12 AM   #25
GoingDown
Zealot
GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.
 
Posts: 114
Karma: 1274
Join Date: Dec 2010
Location: Finland
Device: Kobo Touch
Quote:
Originally Posted by chaley View Post
If I have this right, then create a new custom column named whatever you want. Give it the type 'column built from other columns', and put {author_sort} into the template box. You will now have a column on the library view showing LN, FN (or whatever is in author_sort)
Hi,

Thanks, adding column works beautifully. I have one more question about this subject though:

Can you add this new "Authors LN" column to be appearing to the list in left of the interface (where Authors, Series, Formats etc. are)?
GoingDown is offline   Reply With Quote
Old 12-03-2010, 03:20 AM   #26
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,742
Karma: 6997045
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by GoingDown View Post
Hi,

Thanks, adding column works beautifully. I have one more question about this subject though:

Can you add this new "Authors LN" column to be appearing to the list in left of the interface (where Authors, Series, Formats etc. are)?
No, because it isn't a real column.

The authors column at the left (in the tags pane) is sorted according to each author's sort value. You can see these by right-clicking on an author and choosing manage authors. If these are not how you want authors sorted, then fix them. Note that changing the sort string on this dialog will also update books written by those authors.

If you *really* want both sorts in the tag browser, you can do it manually. Create a text (single value) custom column, which will appear in the tags pane. Then use search/replace to copy author_sort to that column. From time to time you will need to do the copy again, because changes you make to authors, and new books, won't be copied.
chaley is offline   Reply With Quote
Old 12-03-2010, 03:26 AM   #27
GoingDown
Zealot
GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.
 
Posts: 114
Karma: 1274
Join Date: Dec 2010
Location: Finland
Device: Kobo Touch
Quote:
Originally Posted by chaley View Post
No, because it isn't a real column.

The authors column at the left (in the tags pane) is sorted according to each author's sort value. You can see these by right-clicking on an author and choosing manage authors. If these are not how you want authors sorted, then fix them. Note that changing the sort string on this dialog will also update books written by those authors.
Yes, I can see that. I was asking because on my books collection I have authors put in FN LN format, and my authors_sort is LN, FN. This causes the "Authors" view in left to look messy - authors are shown in FN LN, but sort order is different.

I am tempted to change authors to LN, FN, but I am hesitated to make a change. Or, I just make authors_sort to be FN, LN. Which way is preferred?
GoingDown is offline   Reply With Quote
Old 12-03-2010, 03:32 AM   #28
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,742
Karma: 6997045
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by GoingDown View Post
I am tempted to change authors to LN, FN, but I am hesitated to make a change. Or, I just make authors_sort to be FN, LN. Which way is preferred?
Which way is preferred is the way you want it.

The second option seems to be keep FN LN for authors, but make author sort also be FN LN. Some people prefer that, so the list sorts the way it looks. Of course, that means that the author David Weber would sort under 'D', but that seems acceptable.

To do this, set
Code:
author_sort_copy_method = 'copy'
but *do not* change how your authors are entered. Go to manage_authors (discussed above) and push the recalculate button. Voila -- all author_sort values will be set to be the same as the author.
chaley is offline   Reply With Quote
Old 12-03-2010, 06:29 AM   #29
GoingDown
Zealot
GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.GoingDown is no ebook tyro.
 
Posts: 114
Karma: 1274
Join Date: Dec 2010
Location: Finland
Device: Kobo Touch
Thanks chaley! It seems that more I will play with Calibre, more handy features I will find.

When I did the manage_authors - recalculate thing, my Calibre hung up (using 100% cpu). After ~40 minutes, I killed it and started it again, and authors are sorted now differently. So it did seem to work anyway.

I was little bit worried if my database is now somehow inconsistent, so I did "Check database integrity" - which then hung again, 100% cpu usage, the dialog staying at 0% for about one hour (then I killed it again).

Everything still seems to work so no big worries here, and I did a backup before doing anything.

I have lots of (small, mostly pdf or epub) free books loaded, over 1000 authors and way over 5000 books so I am not sure if I should have waited longer for the processes to finish?
GoingDown is offline   Reply With Quote
Old 12-03-2010, 06:36 AM   #30
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 11,742
Karma: 6997045
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by GoingDown View Post
When I did the manage_authors - recalculate thing, my Calibre hung up (using 100% cpu). After ~40 minutes, I killed it and started it again, and authors are sorted now differently. So it did seem to work anyway.
It did some of them, but not all.

That dialog is not optimized for doing thousands of changes at a time. On windows, it will run at the speed of a dead snail. I will look at it, to see if I can do what was done with edit metadata to speed it up.
Quote:
I was little bit worried if my database is now somehow inconsistent, so I did "Check database integrity" - which then hung again, 100% cpu usage, the dialog staying at 0% for about one hour (then I killed it again).
It won't be inconsistent in the sense of broken, but some of the values won't have changed.

And yes, check integrity is slow. Some people have reported that it takes many hours. There isn't much I can do about that, given what it is doing.
Quote:
Everything still seems to work so no big worries here, and I did a backup before doing anything.

I have lots of (small, mostly pdf or epub) free books loaded, over 1000 authors and way over 5000 books so I am not sure if I should have waited longer for the processes to finish?
Yes, you should.
chaley is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Changing from Title-Author to Author - Title Amalthia Calibre 17 01-22-2017 11:20 PM
Adding or changing author denmarks PDF 2 10-05-2009 02:16 PM
Quick newbie question about changing author name and title eawade Calibre 1 06-12-2009 04:37 PM
Changing Title & Author in LRF? fleon Sony Reader 8 01-16-2007 12:43 PM
Changing Title & Author in .lrf files Vienna01 Workshop 1 01-08-2007 05:45 AM


All times are GMT -4. The time now is 07:28 AM.


MobileRead.com is a privately owned, operated and funded community.