Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre

Notices

Reply
 
Thread Tools Search this Thread
Old 08-18-2012, 06:57 PM   #1
Pepin33
Zealot
Pepin33 has a complete set of Star Wars action figures.Pepin33 has a complete set of Star Wars action figures.Pepin33 has a complete set of Star Wars action figures.Pepin33 has a complete set of Star Wars action figures.Pepin33 has a complete set of Star Wars action figures.
 
Posts: 109
Karma: 419
Join Date: Aug 2012
Location: Spain
Device: Kindle Touch
Changing custom columns type?

Is there any way to change custom columns type without loosing its content? (for example, if I have an "integer" column, and I want to change it to "number with decimals").

If the answer is not (I think so), then I suppose the way is to create a new custom column and to copy old values from the other. In this case, is there any way to copy the full column (for all the library) at a time?
Pepin33 is offline   Reply With Quote
Old 08-18-2012, 09:40 PM   #2
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: 31,047
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 Pepin33 View Post
Is there any way to change custom columns type without loosing its content? (for example, if I have an "integer" column, and I want to change it to "number with decimals").

If the answer is not (I think so), then I suppose the way is to create a new custom column and to copy old values from the other. In this case, is there any way to copy the full column (for all the library) at a time?
I think this might work with a composite column:
Do the Shell game with Search and Replace:
Make your new column (you can rename later).
Now select all books that us the custom column
Tap the 'E' key (bulk edit) and select the Search and replace tab
Select your old column to find
the REGEX search term is (.+)
Select your new column as the destination
the REGEX value is \1
Apply
Once you are happy, use the column editor to remove the old column
theducks is online now   Reply With Quote
Advert
Old 08-19-2012, 05:32 AM   #3
Pepin33
Zealot
Pepin33 has a complete set of Star Wars action figures.Pepin33 has a complete set of Star Wars action figures.Pepin33 has a complete set of Star Wars action figures.Pepin33 has a complete set of Star Wars action figures.Pepin33 has a complete set of Star Wars action figures.
 
Posts: 109
Karma: 419
Join Date: Aug 2012
Location: Spain
Device: Kindle Touch
Thanks, theducks.

I tried it, but it didn't work. I get an error "could not convert string to float". I think it's because the REGEX values. ¿?

Edit: Sorry, my mistake. It works. The error I got was because I was selecting some books without any value at the original column. When I select only books with any value at the old column, it works perfectly.

Thanks again, theducks.

Last edited by Pepin33; 08-19-2012 at 07:26 AM.
Pepin33 is offline   Reply With Quote
Old 08-27-2012, 11:23 AM   #4
rolandt99
Member
rolandt99 began at the beginning.
 
Posts: 18
Karma: 10
Join Date: Jun 2012
Device: nook
I am a newbiee so not sure what you mean by the "Shell game with Search and Replace".

In my case I need to change the custom column quality from stars (rating, with 0-5 stars) to integer, as I need to a) reduce screen real-estate usage and b) allow greater than 5 as a value. I would like to do the same with the Rating column as it takes up screen real-estate.

But, when I open Search and Replace the Quality (or #Quality) [nor is Rating] column is not included in the selectable search field drop-down values.

So, what am I doing incorrectly?
rolandt99 is offline   Reply With Quote
Old 08-27-2012, 08:44 PM   #5
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: 31,047
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 rolandt99 View Post
I am a newbiee so not sure what you mean by the "Shell game with Search and Replace".

In my case I need to change the custom column quality from stars (rating, with 0-5 stars) to integer, as I need to a) reduce screen real-estate usage and b) allow greater than 5 as a value. I would like to do the same with the Rating column as it takes up screen real-estate.

But, when I open Search and Replace the Quality (or #Quality) [nor is Rating] column is not included in the selectable search field drop-down values.

So, what am I doing incorrectly?
No rating (type?), I wonder why?

But there is a '{template}'

And the Template to enter is: {rating} (which shows as a number)
theducks is online now   Reply With Quote
Advert
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Editing custom columns JCSullivan Library Management 4 04-12-2012 01:14 PM
Custom columns vs tags Artha Calibre 3 11-22-2011 09:25 AM
Custom Columns - How are you using yours? nynaevelan Library Management 19 04-18-2011 12:42 AM
0.7.46 and custom columns meme Library Management 4 02-21-2011 04:21 AM
Custom Columns - the Future? Starson17 Calibre 2 07-13-2010 09:56 AM


All times are GMT -4. The time now is 12:02 AM.


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