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 07-06-2014, 05:39 PM   #1
rolk
Junior Member
rolk began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Jul 2014
Device: Kobo Aura
Undesired synchronization between title and title_sort

Hi,

I've gone through help files, and the obligatory Google searches but it seems I'm being bothered by a unique problem. Perhaps someone can ease my pain

Here's the thing: I've got a whole bunch of epub's in my Calibre library that have a title formatted something like:

title := "[SomeCategoryName - Number] Actual title"

title_sort is identical to that.

I'm trying to edit the titles of these epubs, I want the stuff between brackets removed, but keep it in title_sort (as I find it quite helpful to keep things together, I just don't want this structuring info be part of the title).

I do this by selecting one of theseepubs and choose edit metadata, individually. Then I change the title. The title_sort field becomes RED, and a helpful message warns me that it is no longer in sync with the title field, but if that is what I want, its allright. I press OK.

The main display shows the updated title, but also the value of title_sort is updated (I have this as a separate column).

The really weird thing is when I then again edit the same epub, I can actually see that the title_sort field has been updated as well, but if I then change title_sort to what I want (basically pasting back in what I cut away from the title in the first edit action), and select OK, presto, title and title_sort are not automagically synchronized.

I'm quite baffled and could use some pointers to resolve this. I suspect it has to do with a Tweaked Preference, but:

I've seen this behaviour on Calibre 1.43, on both OSX as well as Windows 7. The latter is even a fresh install in which I haven't changed anything except adding this column to the main display.

rolk is offline   Reply With Quote
Old 07-06-2014, 06:35 PM   #2
LisaAlissa
Member
LisaAlissa began at the beginning.
 
Posts: 19
Karma: 10
Join Date: Jul 2011
Device: iPad, iPhone,
Hi Rolk,

I don't know how to fix your problem, as you state it, but am wondering if you're using the Series designation, and associated numbering on the "editing metadata" pop-up window?

If so, you may not need as much of the bracketed material in your title. Which would get rid of your problem altogether.

I should note that even though I do use series designators and numbering, I often add a (#) at the end of a title, where the # is the Series #. I do that so that I can easily find the numbered one I want among an author's works in the Calibre library when "sideloading" books out of Calibre into a specific reading app using iTunes.

So the title field for a book called The Book which was the 3rd in a series called The Ultimate Series would look like this:

The Book (3)

and the title sort field would look like this:

Book (3), The

which works for my purposes.

I should note that when choosing a Series designation, I try to always delete articles (like "the", "a" and "an") from the "official series titles" as those aren't useful and make the dropdown menu in the search pop-up window less helpful when I'm searching for a series name.

so the Series would read like this:

"Ultimate"

and the number would read "3"


HTH,

Lisa
LisaAlissa is offline   Reply With Quote
Old 07-06-2014, 06:39 PM   #3
BetterRed
null operator (he/him)
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 21,660
Karma: 29711016
Join Date: Mar 2012
Location: Sydney Australia
Device: none
@rolk - IMO you're expecting the title_sort column to behave in a manner that's contrary to its design purpose.

I would advise separating the "[SomeCategoryName - Number]" part of your titles into a discrete custom column - eg mycategory. Maybe based on calibres Series type column. You should then be able to use a regular expression in Bulk Metadata Edit Search and Replace to remove it from the Title column, and put it in the mycategory column .

Then you could create another custom column (column built from other columns) - egg mytitlesort. It would built via a template that wrapped the mycategory in brackets and appending title_sort. But that said, I would question why you'd want do that. If its for sorting, then maybe the View Manager would be a better solution for you. If its for Send to Device and/or Save to Disk then Send To and/or Save As templates/plugboards would be a better solution - its what they're designed to do.

BR

Last edited by BetterRed; 07-06-2014 at 06:41 PM.
BetterRed is offline   Reply With Quote
Old 07-07-2014, 03:10 AM   #4
rolk
Junior Member
rolk began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Jul 2014
Device: Kobo Aura
Hi Lisa,

Thanks for your reply. I like the idea of postfixing a braced number, I think I'm going to adopt that style.

Quote:
Originally Posted by LisaAlissa View Post

Book (3), The

which works for my purposes.
So in the way you suggest 'Ultimate' ends up in the Series field right? How does this work in the main display? I thought the main display sorts books based on title_sort, which is why I'm trying to maintain that separate from the title field.

Suppose your series is called 'The Ultimate Series' and has three books:

'The Ultimate Series - Introduction to Ultimate'
'The Ultimate Series - More Ultimate'
'The Ultimate Series - The Ultimate Ultimate'

And you also have another publication by the same author:

'Nothing Ultimate'

not part of this series.

Then you'd have the following entries:

Code:
title                         title_sort                          series
Introduction to Ultimate (1)  Brief Introduction to Ultimate      Ultimate
More Ultimate (2)             More Ultimate                       Ultimate
The Ultimate Ultimate (3)     The Ultimate Ultimate               Ultimate
Nothing Ultimate              Nothing Ultimate
Now, wouldn't the title_sort field cause the main display to display these books as:

Code:
title                         title_sort                          series
Introduction to Ultimate (1)  Brief Introduction to Ultimate      Ultimate
More Ultimate (2)             More Ultimate                       Ultimate
Nothing Ultimate              Nothing Ultimate
The Ultimate Ultimate (3)     The Ultimate Ultimate               Ultimate
My thought was to use title_sort to keep this a bit organized. In this example, I'd like it so that all 'Ultimate' publications are kept close together, but perhaps there is a better way.
rolk is offline   Reply With Quote
Old 07-07-2014, 03:22 AM   #5
rolk
Junior Member
rolk began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Jul 2014
Device: Kobo Aura
Quote:
Originally Posted by BetterRed View Post
@rolk - IMO you're expecting the title_sort column to behave in a manner that's contrary to its design purpose.
That seems to be the case. I'm a bit confused concerning the exact purpose of title_sort. I'll try to read up on it.

Quote:
I would advise separating the "[SomeCategoryName - Number]" part of your titles into a discrete custom column - eg mycategory. Maybe based on calibres Series type column.
I was trying to use title_sort to achieve a clustering effect, perhaps that is a bad idea. I need to find out how calibre is sorting the list of publications. I'll look into the View Manager and see how that can help.

Still, I think it is pretty weird behaviour for a user interface to:

1) warn about two fields having distinct values
2) reassure you that if that is what you want, everything is fine
3) when you click ok, it sneaks in behind your back and changes the second field to match the first field anyway!

4) ...or this behaviour is somewhere enabled/activated by a tweak or plugin and I haven't been able to find out where.

And the weirdest thing is that the same dialog does allow distinct values between the two (title and title_sort) as long as you do not edit the title field. Editing the title field triggers this 'automagical synchronization'.

Downloading the source code right now, I'll have a look at how this dialog is handled.
rolk is offline   Reply With Quote
Old 07-07-2014, 03:57 AM   #6
itimpi
Wizard
itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.
 
Posts: 4,553
Karma: 950151
Join Date: Nov 2008
Device: Sony PRS-950, iphone/ipad (Marvin/iBooks/QuickReader)
Quote:
Originally Posted by rolk View Post
Hi Lisa,

Thanks for your reply. I like the idea of postfixing a braced number, I think I'm going to adopt that style.



So in the way you suggest 'Ultimate' ends up in the Series field right? How does this work in the main display? I thought the main display sorts books based on title_sort, which is why I'm trying to maintain that separate from the title field.

Suppose your series is called 'The Ultimate Series' and has three books:

'The Ultimate Series - Introduction to Ultimate'
'The Ultimate Series - More Ultimate'
'The Ultimate Series - The Ultimate Ultimate'

And you also have another publication by the same author:

'Nothing Ultimate'

not part of this series.

Then you'd have the following entries:

Code:
title                         title_sort                          series
Introduction to Ultimate (1)  Brief Introduction to Ultimate      Ultimate
More Ultimate (2)             More Ultimate                       Ultimate
The Ultimate Ultimate (3)     The Ultimate Ultimate               Ultimate
Nothing Ultimate              Nothing Ultimate
Now, wouldn't the title_sort field cause the main display to display these books as:

Code:
title                         title_sort                          series
Introduction to Ultimate (1)  Brief Introduction to Ultimate      Ultimate
More Ultimate (2)             More Ultimate                       Ultimate
Nothing Ultimate              Nothing Ultimate
The Ultimate Ultimate (3)     The Ultimate Ultimate               Ultimate
My thought was to use title_sort to keep this a bit organized. In this example, I'd like it so that all 'Ultimate' publications are kept close together, but perhaps there is a better way.
No - that is not how it would display. The number within a series is appended to the Series entry - not the title field.

What I normally do is click first on the title field to get sorted by title, and then on the Series field. Doing that results in title_sort order within series order. The net effect is that those without a series entry end up at the top in title_sort order (as they all have the same empty value for series), but the ones in series are sorted by series name/number as there is normally only a single books with a given series+series number value..
itimpi is offline   Reply With Quote
Old 07-07-2014, 06:41 AM   #7
rolk
Junior Member
rolk began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Jul 2014
Device: Kobo Aura
Quote:
Originally Posted by itimpi View Post
No - that is not how it would display. The number within a series is appended to the Series entry - not the title field.

What I normally do is click first on the title field to get sorted by title, and then on the Series field. Doing that results in title_sort order within series order. The net effect is that those without a series entry end up at the top in title_sort order (as they all have the same empty value for series), but the ones in series are sorted by series name/number as there is normally only a single books with a given series+series number value..
Thanks. This seems like a perfectly acceptable way to achieve what I want, without messing with the title_sort field.

That being said though, I'm still a bit in the dark as why editing the title field in 'edit metadata - individually' also updates the title_sort field. Especially since the UI gives me a fair warning:

"The red color warns that the current
title sort does not match the current title.
No action is required if this is what you want."

In the tooltip of the title_sort (appears in red).

I'm debugging this using the latest state of affairs from the git repository. When I close the dialog, I only see one commit (for the TITLE_ATTR="title"), so if my debugging is correct, it is not the actual metadata edit dialog that causes the title_sort field to be set to match the title. It has got to be something that is triggered after the dialog is closed.
rolk is offline   Reply With Quote
Old 07-07-2014, 10:14 AM   #8
itimpi
Wizard
itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.
 
Posts: 4,553
Karma: 950151
Join Date: Nov 2008
Device: Sony PRS-950, iphone/ipad (Marvin/iBooks/QuickReader)
Quote:
Originally Posted by rolk View Post

That being said though, I'm still a bit in the dark as why editing the title field in 'edit metadata - individually' also updates the title_sort field. Especially since the UI gives me a fair warning:

"The red color warns that the current
title sort does not match the current title.
No action is required if this is what you want."

In the tooltip of the title_sort (appears in red).

I'm debugging this using the latest state of affairs from the git repository. When I close the dialog, I only see one commit (for the TITLE_ATTR="title"), so if my debugging is correct, it is not the actual metadata edit dialog that causes the title_sort field to be set to match the title. It has got to be something that is triggered after the dialog is closed.
I must admit it is puzzling. In my case if I use the Eit Metadata dialog and manually Edit the Title field I do NOT get the Title_Sort field updated with no intervention from me. It DOES get updated automatically if I use the Download Metadata button - but in that case I can see the change has been made before I press the OK button.

I wonder if here is a tweak that can affect this behaviour?
itimpi is offline   Reply With Quote
Old 07-07-2014, 10:20 AM   #9
LisaAlissa
Member
LisaAlissa began at the beginning.
 
Posts: 19
Karma: 10
Join Date: Jul 2011
Device: iPad, iPhone,
Quote:
Originally Posted by rolk View Post
Hi Lisa,

Thanks for your reply. I like the idea of postfixing a braced number, I think I'm going to adopt that style. .
Hi Rolk,

You’re welcome.

Quote:
Originally Posted by rolk View Post
So in the way you suggest 'Ultimate' ends up in the Series field right? How does this work in the main display? I thought the main display sorts books based on title_sort, which is why I'm trying to maintain that separate from the title field. .
Actually the main display is capable of much more than this. It can sort based on most (any?) of the columns. I usually keep mine sorted based on “Date” (which is the date I added the book). But you should experiment a bit to see what you prefer. Click on the title of that column, and it will rearrange based on that. If you prefer a reverse-chron order, click the column again (see the small arrow at the top of the column to see which way the column is being sorted). So it can also sort based on (among other things) Series, Title, Author, Ratings, values in your custom columns, even first or last (in alpha order) Tag!

Try clicking on the various columns and see what you get. You can limit the number of things displayed in the main display by using either the "Tag Browser" (which doesn't necessarily have anything to do w/ tags) or the advanced search pop-up window. The four buttons in the lower left-hand corner of the main display are toggle buttons. You can show or not show various elements (to allow you to conserve screen space as you find it most useful). One of the elements you can show is the Tag Browser, which will allow you to limit the display to various sub-sets of your library.

You'll note that using either the Tag Browser or the Search pop-up will add values to the "search bar"...which you can ignore (as the Tag Browser or Search pop-up is managing the search terms for you). But it's useful to note that you can return to your main display (and all of it's entries) by clicking the black-arrow-with-an-x-on-it which is to the right of the "Go!" button.

Quote:
Originally Posted by rolk View Post
Suppose your series is called 'The Ultimate Series' and has three books:

'The Ultimate Series - Introduction to Ultimate'
'The Ultimate Series - More Ultimate'
'The Ultimate Series - The Ultimate Ultimate'

And you also have another publication by the same author:

'Nothing Ultimate'

not part of this series.

Then you'd have the following entries:

Code:
title                         title_sort                          series
Introduction to Ultimate (1)  Brief Introduction to Ultimate      Ultimate
More Ultimate (2)             More Ultimate                       Ultimate
The Ultimate Ultimate (3)     The Ultimate Ultimate               Ultimate
Nothing Ultimate              Nothing Ultimate
Now, wouldn't the title_sort field cause the main display to display these books as:

Code:
title                         title_sort                          series
Introduction to Ultimate (1)  Brief Introduction to Ultimate      Ultimate
More Ultimate (2)             More Ultimate                       Ultimate
Nothing Ultimate              Nothing Ultimate
The Ultimate Ultimate (3)     The Ultimate Ultimate               Ultimate

My thought was to use title_sort to keep this a bit organized. In this example, I'd like it so that all 'Ultimate' publications are kept close together, but perhaps there is a better way.
"Title Sort" isn't actually a separate column (in the main display)—it's just how Calibre will sort the Title column (if you choose to sort by Title). For example, not alphabetizing using "The" and "A" and "An" (which the "title sort" field therefore shows as dropped to the end of the title in the "Edit Metadata" pop-up). So your middle column (in your examples) will never actually be shown in the main display. You'll see these only on the "Edit Metadata" pop-up. If you see a sort of the Title column that seems odd, you can check why Calibre sorted that way by checking the Title Sort field on the Metadata pop-up.

The main display would make a couple of changes to what you suggest here (I'll mark them in red), but before I do, let's add a short story between books 1 & 2 in the Ultimate series to your list. While the numbers in the Series designation increment by whole numbers by default (in the Edit Metadata pop-up), you can edit them to fractions like this: The Ultimate Story (1.5). If I then sort in the main display, using the Title column, I'll get this (note that the middle column below won't display...I've left it in the example below only so you see why the title column will be displayed in this order, instead of putting the short story at the top of the list):

Code:
title                         title_sort                     series
Introduction to Ultimate (1)  /\Introduction to Ultimate (1) Ultimate [1]
More Ultimate (2)             More Ultimate (1)              Ultimate [2]
Nothing Ultimate              Nothing Ultimate
An Ultimate Story (1.5)       Ultimate Story (1.5), An       Ultimate [1.5]  
The Ultimate Ultimate (3)     Ultimate Ultimate (3), The     Ultimate [3]
If you use your Tag Browser to select the author of the "Ultimate Series" (green plus next to name in the Tag Browser—red minus will exclude those entries from the main display and category icon will have no effect on the display) and then choose a Series sort for the main display you'll get this:

Code:
title                           series
Nothing Ultimate        
Introduction to Ultimate (1)    Ultimate [1]
An Ultimate Story (1.5)         Ultimate [1.5]
More Ultimate (2)               Ultimate [2]
The Ultimate Ultimate (3)       Ultimate [3]
If you sort by title, in reverse alpha order (click the title of the column twice) you get this:
Code:
title                             series

The Ultimate Ultimate (3)         Ultimate [3]
An Ultimate Story (1.5)           Ultimate [1.5]
Nothing Ultimate             
More Ultimate (2)                 Ultimate [2]
Introduction to Ultimate (1)      Ultimate [1]
But returning to the question of adding series info to the title, you'll notice that the Series list includes all of the series numbers...so for purposes of the main display, you don't need the numbers in parentheses that I add to titles. I add them because they're useful when I'm using iTunes to access my Calibre library to add a book to a reading app on either my iPad or iPhone. When I'm doing that, I can't see the Calibre main display, just a list of authors, and once I select an author, that author's book titles, as shown in Calibre. If it wasn't for this, I probably wouldn't bother adding series numbers to titles.

BTW, if you don't like the columns you have, or the order they're in, you can change that too. For example, I use two custom columns to manage my reading and explain that here: https://www.mobileread.com/forums/sho...d.php?t=242247

HTH,

Lisa

Last edited by LisaAlissa; 07-07-2014 at 10:27 AM.
LisaAlissa is offline   Reply With Quote
Old 07-07-2014, 12:01 PM   #10
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 30,942
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Quote:
Originally Posted by itimpi View Post
I must admit it is puzzling. In my case if I use the Eit Metadata dialog and manually Edit the Title field I do NOT get the Title_Sort field updated with no intervention from me. It DOES get updated automatically if I use the Download Metadata button - but in that case I can see the change has been made before I press the OK button.

I wonder if here is a tweak that can affect this behaviour?
I have been seeing an auto update (after depart book?) even without the button when using Next/Previous. A single (OK) did not do this the last few edits).. In other words: Red when I left. Green when I returned for Title and Author
theducks is offline   Reply With Quote
Reply

Tags
title title_sort sync


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Template language uses title_sort instead of title eMole Calibre 2 03-11-2014 07:22 AM
"Save to disc" using title instead of title_sort? manawydan Library Management 4 09-22-2013 01:52 AM
Using {title} or {title_sort} with save gives the same result DrChiper Calibre 3 05-23-2013 02:53 AM
Title during 'save to disk' gets changed to title_sort miquele Library Management 2 09-02-2012 12:11 PM


All times are GMT -4. The time now is 01:59 PM.


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