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 06-07-2019, 10:46 PM   #1
Ahu Lee
Member
Ahu Lee began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Jan 2013
Device: none
Adding custom column with any lookup-name gives me empty column as a result?

I'm trying to add a custom column, but no matter what I choose, it results in an empty column.

For example:
  1. I go to Add your own columns dialog box
  2. Create a custom column using the following. Lookup name: timestamp; Column heading: New Column; Column type: Date; Format for dates: yyyy)
  3. Click Ok, Apply. Restart
Here I'm expecting to see a new column filled with four-digit numbers (the same ones I see in the original Date column, which also use timestamp lookup-name), but my new column is totally empty.

Why? Am I missing something here?

Last edited by Ahu Lee; 06-07-2019 at 11:00 PM.
Ahu Lee is offline   Reply With Quote
Old 06-07-2019, 11:03 PM   #2
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: 20,553
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
The attributes of Built-in Columns (the ones without an ionic column symbol) cannot be changed via Add your own Custom Columns.

There's a Tweak for date formats, viz:

Click image for larger version

Name:	Clipboard01.jpg
Views:	426
Size:	200.6 KB
ID:	171827

BR
BetterRed is offline   Reply With Quote
Advert
Old 06-07-2019, 11:37 PM   #3
Ahu Lee
Member
Ahu Lee began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Jan 2013
Device: none
Quote:
Originally Posted by BetterRed View Post
The attributes of Built-in Columns (the ones without an ionic column symbol) cannot be changed via Add your own Custom Columns.

There's a Tweak for date formats, viz:

Attachment 171827

BR
Are you saying that I should have used the same date format as set in my tweak or what? Sorry, I'm not sure I understand you.

In my tweak the timestamp format is set as yyyy-MM-dd. In the Edit custom column dialog it says "Default: dd MMM yyyy" on the right side of the "Format for dates" field. I tried both. Nothing changed.

I can also, for example, use the authors variable/lookup-name with text column type and it will also be empty.

Last edited by Ahu Lee; 06-07-2019 at 11:47 PM.
Ahu Lee is offline   Reply With Quote
Old 06-08-2019, 12:02 AM   #4
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: 20,553
Karma: 26954694
Join Date: Mar 2012
Location: Sydney Australia
Device: none
If you want the timestamp/Date column displayed as 'YYYY', you need to change the setting I posted before in Preferences->Advanced->Tweaks, viz:

Click image for larger version

Name:	3.jpg
Views:	275
Size:	83.4 KB
ID:	171829

You may have to scroll Preferences windows to get to Advanced. Search for 'date'

You can only add or change Custom columns in Preferences->Add your own columns - e.g. the ones in the red box, viz:

Click image for larger version

Name:	4.jpg
Views:	302
Size:	150.4 KB
ID:	171830

The built-in columns are in that list so you can a) include/exclude Book List columns and b) order the Book List columns.

BR
BetterRed is offline   Reply With Quote
Old 06-08-2019, 12:42 AM   #5
Ahu Lee
Member
Ahu Lee began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Jan 2013
Device: none
Quote:
Originally Posted by BetterRed View Post
If you want the timestamp/Date column displayed as 'YYYY', you need to change the setting I posted before in Preferences->Advanced->Tweaks, viz:

Attachment 171829

You may have to scroll Preferences windows to get to Advanced. Search for 'date'

You can only add or change Custom columns in Preferences->Add your own columns - e.g. the ones in the red box, viz:

Attachment 171830

The built-in columns are in that list so you can a) include/exclude Book List columns and b) order the Book List columns.

BR
Please don't be so fixated on this date thing. I never said anywhere that I want my date column to be displayed in this or that way. My question is not about date at all. I used it as an example, okay.

I also understand what the word 'custom' means. And I'm not trying to change any column which is not custom.

So, now once the above is established I can only try to repeat/rephrase what my problem/confusion is about.

There are different default lookup-names in Calibre (title, size, timestamp, authors etc.). I think of them as variables of sort. Am I right about it or wrong? And since I think of them as kind of variables I expect that they can be called. Am I right about it or wrong? So, I expected I could use those lookup names/variables in my custom column, but apparently it's not so, because all I got were empty columns. So, non-working (as I expect them to) lookup-names is my issue. That's what I don't understand and that's where I need help.

Last edited by Ahu Lee; 06-08-2019 at 01:02 AM.
Ahu Lee is offline   Reply With Quote
Advert
Old 06-08-2019, 01:14 AM   #6
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,843
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
If you wan tto create a column that shows data from other columns it has to be of type "Column built from other clumns" and you have to specify a template for it. https://manual.calibre-ebook.com/template_lang.html
kovidgoyal is offline   Reply With Quote
Old 06-08-2019, 01:34 AM   #7
Ahu Lee
Member
Ahu Lee began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Jan 2013
Device: none
Quote:
Originally Posted by kovidgoyal View Post
If you wan tto create a column that shows data from other columns it has to be of type "Column built from other clumns" and you have to specify a template for it. https://manual.calibre-ebook.com/template_lang.html
Great. Thank you, I'll look into it. But what do I do if the lookup name I want to use is not related to any other columns data. For example, I'm particularly interested in "author_sort" (I've found it on "Title/author/series" tab of "Advanced search dialog"). Should I still use "Column built from other columns" in this case?
Ahu Lee is offline   Reply With Quote
Old 06-08-2019, 01:59 AM   #8
Sunlite
Addict
Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.
 
Sunlite's Avatar
 
Posts: 206
Karma: 547516
Join Date: Mar 2008
Location: Berlin, Germany
Device: KObo Clara, Kobo Aura, PRS-T1, PB602, CyBook Gen3
Custom columns are mainlya way for you to store information for your books not fitting the standard columns. When they are created, they are empty. You can then fill them with your info.

"Column built from other columns" is a way to combine existing informations and make it available in searches and templates.
Too many columns of this kind can slow down your library, because the information is always calculated on the fly.


To use author_sort you do not need a custom column, that is already a lookup name

Edit: Maybe you could tell us what goal you want to reach? There might be a way there, you are not seeing right now.

Last edited by Sunlite; 06-08-2019 at 02:01 AM.
Sunlite is offline   Reply With Quote
Old 06-08-2019, 02:13 AM   #9
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 35,307
Karma: 145435140
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Forma, Clara HD, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by Ahu Lee View Post
There are different default lookup-names in Calibre (title, size, timestamp, authors etc.). I think of them as variables of sort. Am I right about it or wrong? And since I think of them as kind of variables I expect that they can be called. Am I right about it or wrong? So, I expected I could use those lookup names/variables in my custom column, but apparently it's not so, because all I got were empty columns. So, non-working (as I expect them to) lookup-names is my issue. That's what I don't understand and that's where I need help.
Unless you use one of the two column built from other columns functionality, how is your new column going to get any information? I have a column called Additional Authors and it remains empty until I populate it manually--that column is used mostly for multi-author collections of short stories.
DNSB is offline   Reply With Quote
Old 06-08-2019, 02:31 AM   #10
Ahu Lee
Member
Ahu Lee began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Jan 2013
Device: none
Quote:
Originally Posted by Sunlite View Post
Custom columns are mainlya way for you to store information for your books not fitting the standard columns. When they are created, they are empty. You can then fill them with your info.

"Column built from other columns" is a way to combine existing informations and make it available in searches and templates.
Too many columns of this kind can slow down your library, because the information is always calculated on the fly.


To use author_sort you do not need a custom column, that is already a lookup name

Edit: Maybe you could tell us what goal you want to reach? There might be a way there, you are not seeing right now.
Thank you. My goal is/was to create a custom column where I could use "Author sort" field as author's name. For that I wanted to use "author_sort" lookup name, similar to how Author(s) column "uses" "authors" one. But, now I see that's not possible, because these lookup-names are defensively not what I initially thought them to be.

Just to clarify. So, is it true that there's no way for me to have a column in Calibre which would use "Author sort" field instead of "Author(s)" one? Or it can be done applying some Python magic somewhere at least?

Last edited by Ahu Lee; 06-08-2019 at 02:36 AM.
Ahu Lee is offline   Reply With Quote
Old 06-08-2019, 03:00 AM   #11
Ahu Lee
Member
Ahu Lee began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Jan 2013
Device: none
Quote:
Originally Posted by DNSB View Post
Unless you use one of the two column built from other columns functionality, how is your new column going to get any information? I have a column called Additional Authors and it remains empty until I populate it manually--that column is used mostly for multi-author collections of short stories.
I initially thought that columns could get information from .opf files. For example, information I'm interested in is under "opf:file-as" attribute of the <dc:creator> tag. The program should be able to reach it. And it obviously does so, otherwise it wouldn't be there and the "Author sort field" in "Edit Metadata" would be always empty.

Last edited by Ahu Lee; 06-08-2019 at 03:08 AM.
Ahu Lee is offline   Reply With Quote
Old 06-08-2019, 03:21 AM   #12
Sunlite
Addict
Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.Sunlite ought to be getting tired of karma fortunes by now.
 
Sunlite's Avatar
 
Posts: 206
Karma: 547516
Join Date: Mar 2008
Location: Berlin, Germany
Device: KObo Clara, Kobo Aura, PRS-T1, PB602, CyBook Gen3
Quote:
Originally Posted by Ahu Lee View Post
Just to clarify. So, is it true that there's no way for me to have a column in Calibre which would use "Author sort" field instead of "Author(s)" one? Or it can be done applying some Python magic somewhere at least?
No, that is not true!

You can creat a custom column with "Column built from other columns" from type "Text" with the template {author_sort}.
After a restart of Calibre this column will display the value of author_sort.
Sunlite is offline   Reply With Quote
Old 06-08-2019, 03:50 AM   #13
Ahu Lee
Member
Ahu Lee began at the beginning.
 
Posts: 21
Karma: 10
Join Date: Jan 2013
Device: none
Quote:
Originally Posted by Sunlite View Post
No, that is not true!

You can creat a custom column with "Column built from other columns" from type "Text" with the template {author_sort}.
After a restart of Calibre this column will display the value of author_sort.
That did what I wanted! But I should say this was absolutely counterintuitive to me. "Column built from other columns" could be called "The quick brown fox jumps over the lazy dog" and it would make as much sense to me.
Ahu Lee is offline   Reply With Quote
Old 06-08-2019, 07:59 AM   #14
Bookstooge
Guru
Bookstooge ought to be getting tired of karma fortunes by now.Bookstooge ought to be getting tired of karma fortunes by now.Bookstooge ought to be getting tired of karma fortunes by now.Bookstooge ought to be getting tired of karma fortunes by now.Bookstooge ought to be getting tired of karma fortunes by now.Bookstooge ought to be getting tired of karma fortunes by now.Bookstooge ought to be getting tired of karma fortunes by now.Bookstooge ought to be getting tired of karma fortunes by now.Bookstooge ought to be getting tired of karma fortunes by now.Bookstooge ought to be getting tired of karma fortunes by now.Bookstooge ought to be getting tired of karma fortunes by now.
 
Bookstooge's Avatar
 
Posts: 760
Karma: 2090886
Join Date: May 2019
Device: Kindle Oasis 1st Gen
Quote:
Originally Posted by Ahu Lee View Post
That did what I wanted! But I should say this was absolutely counterintuitive to me. "Column built from other columns" could be called "The quick brown fox jumps over the lazy dog" and it would make as much sense to me.
Well, now you are a wiser and better person for having learned something!
Bookstooge is offline   Reply With Quote
Old 06-08-2019, 10:39 AM   #15
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: 29,779
Karma: 54830978
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 Ahu Lee View Post
That did what I wanted! But I should say this was absolutely counterintuitive to me. "Column built from other columns" could be called "The quick brown fox jumps over the lazy dog" and it would make as much sense to me.
While it said 'from other', it did not mandate that you must use more than one (which is what a lot of people mostly do).

As others have pointed out: table (more columns and those 'built') bloat, slow things down. The bigger the Library, the more important this becomes.
FWIW
Code:
author_sort:jones
is a valid Search term, even though you can't see the column. And sorting on the Authors column (as shipped settings) really uses {author_sort}, but you Still SEE the authors first name, but in the proper order
Anne Lee Jones
Mary Jones
Wilbur Jones
(or
Jones, Anne Lee
Jones, Mary
Jones, Wilbur
)
theducks is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to add checking for an empty custom column using Quality Check plug-in? pg111 Calibre 11 11-13-2018 12:26 AM
Move selected data from series column to a new custom column fvdham Library Management 3 06-02-2017 03:49 PM
Can I have a custom column filled when adding books? LadyKate Library Management 1 10-01-2016 10:58 PM
Crash when adding a custom (built) column MidwestJen Library Management 13 12-06-2014 03:52 PM
Adding books to custom column Gazella Calibre 2 12-27-2012 11:28 AM


All times are GMT -4. The time now is 08:48 AM.


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