08-17-2011, 07:52 PM | #1 |
Junior Member
Posts: 7
Karma: 10
Join Date: Aug 2011
Device: none
|
How do I populate a custom field on import?
My files are in this order
Lastname, Firstname - [Series 02] - Book title and Lastname, Firstname - [Series name 01] - Book Title [read] I want to have any book marked [read] to show in the custom column I created on import so I do not have to manually edit them. I found these snippets from a penguinaka that work well for importing the books but not sure how to deal with the custom column. ^(?P<author>[^-]+)(\s*-\s*(\[?(?P<series>[^-0-9]+)\s*(?P<series_index>[0-9.]+)?]?)?)?.*?-\s*(?P<title>[^\]{[()]+\w) this one removes all brackets around the series and anything in brackets in the title section doesn't get imported imported ^(?P<author>[^-]+)(\s*-\s*(\[?(?P<series>[^-0-9]+)\s*(?P<series_index>[0-9.]+)?]?)?)?.*?-\s*(?P<title>[^-]+) this one removes brackets around the series section but leaves things in brackets in the title so you get version information imported with the title |
08-17-2011, 11:15 PM | #2 |
Wizard
Posts: 4,812
Karma: 26912940
Join Date: Apr 2010
Device: sony PRS-T1 and T3, Kobo Mini and Aura HD, Tablet
|
Perhaps not what you are looking for, but if you do a search for [read], drag those files to calibre and then bulk edit to populate the read column.
Helen |
Advert | |
|
08-18-2011, 01:55 AM | #3 |
Wizard
Posts: 3,130
Karma: 91256
Join Date: Feb 2008
Location: Germany
Device: Cybook Gen3
|
You can only import into the columns shown in the add books preferences screen. You can, however, import into another column and use bulk metadata edit to move (parts of) the columns content to your custom column.
|
08-18-2011, 02:12 PM | #4 |
Junior Member
Posts: 7
Karma: 10
Join Date: Aug 2011
Device: none
|
Ok. Will try that thanks
|
08-19-2011, 03:08 PM | #5 |
Junior Member
Posts: 2
Karma: 10
Join Date: Aug 2011
Device: kindle, iPad
|
How exactly do you do that? All I see in the bulk metadata edit is a search/replace function, no move/copy as far as I can tell.
|
Advert | |
|
08-19-2011, 03:19 PM | #6 |
Well trained by Cats
Posts: 30,392
Karma: 58053698
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
|
08-19-2011, 03:36 PM | #7 |
Wizard
Posts: 3,130
Karma: 91256
Join Date: Feb 2008
Location: Germany
Device: Cybook Gen3
|
In regular expression search mode, you can use backreferences in the replace text. Also, your destination field doesn't have to match the source field.
|
08-19-2011, 03:37 PM | #8 |
Junior Member
Posts: 2
Karma: 10
Join Date: Aug 2011
Device: kindle, iPad
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Add Book Regex to Custom field | adept22 | Library Management | 3 | 10-07-2014 07:33 PM |
Question about populating custom field | jmricker | Plugins | 3 | 08-09-2014 02:10 PM |
Search Replcae error on custom field | adept22 | Library Management | 4 | 03-14-2011 09:47 AM |
Custom Metadata Field | gpp | Sigil | 6 | 02-22-2011 08:39 AM |
Bulk Meta Data Edit Resetting Custom Field | toomuchreading | Calibre | 8 | 10-22-2010 10:19 PM |