Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader

Notices

Reply
 
Thread Tools Search this Thread
Old 11-29-2015, 09:58 AM   #1
kwokhin
Enthusiast
kwokhin began at the beginning.
 
Posts: 46
Karma: 10
Join Date: May 2015
Device: Kobo Glo HD
How do I export notes (annotation) to my computer?

Hello guys, I'm very frustrated as I've been working on exporting my notes to the computer.
http://www.albertopettarin.it/exportnotes.html
I tried the above method but it says:
"provided file is not a valid KoboReader.sqlite db"



http://netlaze.blogspot.hk/2012/10/h...ions-from.html
Then I tried this method. I have all the four files but when I clicked the work.bat, it just flashed and nothing happened.

HOW CAN I EXPORT MY NOTES?
I wouldn't have asked for help if I had not tried to figure it out first. But I really couldn't do it. PLEASE HELP!

Last edited by kwokhin; 11-29-2015 at 10:04 AM.
kwokhin is offline   Reply With Quote
Old 11-29-2015, 10:52 AM   #2
PeterT
Grand Sorcerer
PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.
 
PeterT's Avatar
 
Posts: 12,373
Karma: 74317822
Join Date: Nov 2007
Location: Toronto
Device: Nexus 7, Clara, Touch, Tolino EPOS
Where did you copy the files from your Kobo too?
PeterT is offline   Reply With Quote
Old 11-29-2015, 12:25 PM   #3
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: 37,561
Karma: 149859356
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by kwokhin View Post
HOW CAN I EXPORT MY NOTES?
I wouldn't have asked for help if I had not tried to figure it out first. But I really couldn't do it. PLEASE HELP!
I took a quick look at the method you were using and with some minor changes, it worked for me.

work.cmd (same as work.bat, the %~dp0 just points to directory file is run from)

Code:
%~dp0sqlite3.exe KoboReader.sqlite <extr_annotations.txt
extr_annotations.txt (modified to insert \r\n instead of rn for new line and use annotations.txt instead of annotations.doc)

Code:
.output annotations.txt
.separator \r\n
 SELECT VolumeID, Text, Annotation
 FROM Bookmark;
.exit

I copied sqlite3.exe and the sqlite database from my H2O into the directory and after running, I had the annotations.txt file.

OTOH, my personal preference for extracting annotations which was also somewheres on Mobileread a while back used a single batch file with a rather long command line to do the extract from the database on the Kobo itself, doing some cleanup on the results and leaving them in the same directory as the .cmd file in a file called annotations.html. Basically, just need extr_annotations.cmd and the sqlite3 executable in a directory and the Kobo ereader connected (for me, the internal storage mounts as drive E: so if yours mounts in a different spot, you'll need to change that ( E:\.kobo to whatever:\.kobo ). The pause at the end of the batch file just keeps the DOS box open so I can see any error messages.

extr_annotations.cmd

Code:
%~dp0SQLite3.exe "E:\.kobo\KoboReader.sqlite" "select (case when datecreated=maxdate then ('<b><i><u>' || replace(volumeid,'file:///mnt/onboard/','') || '</u></i></b><br />') else '' end), max(datecreated, coalesce(datemodified, 0)), text, coalesce(annotation, '') || '<br />' from ( select *, (select max(datecreated) from bookmark where volumeid=bm.volumeid and (text<>'' or annotation<>'')) maxdate from bookmark bm where (text<>'' or annotation<>'') order by maxdate desc, volumeid, datecreated desc )" > "%~dp0annotations.html"

pause

Last edited by DNSB; 11-29-2015 at 07:44 PM.
DNSB is offline   Reply With Quote
Old 11-29-2015, 07:40 PM   #4
kwokhin
Enthusiast
kwokhin began at the beginning.
 
Posts: 46
Karma: 10
Join Date: May 2015
Device: Kobo Glo HD
Quote:
Originally Posted by PeterT View Post
Where did you copy the files from your Kobo too?
I copied my KoboReader.sqlite from .Kobo
kwokhin is offline   Reply With Quote
Old 11-29-2015, 07:44 PM   #5
PeterT
Grand Sorcerer
PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.PeterT ought to be getting tired of karma fortunes by now.
 
PeterT's Avatar
 
Posts: 12,373
Karma: 74317822
Join Date: Nov 2007
Location: Toronto
Device: Nexus 7, Clara, Touch, Tolino EPOS
But where did you put them on the PC? The command you have typed says look in the current directory c:\python27 for them.
PeterT is offline   Reply With Quote
Old 11-29-2015, 07:47 PM   #6
kwokhin
Enthusiast
kwokhin began at the beginning.
 
Posts: 46
Karma: 10
Join Date: May 2015
Device: Kobo Glo HD
Quote:
Originally Posted by DNSB View Post
I took a quick look at the method you were using and with some minor changes, it worked for me.

work.cmd (same as work.bat, the %~dp0 just points to directory file is run from)

Code:
%~dp0sqlite3.exe KoboReader.sqlite <extr_annotations.txt
extr_annotations.txt (modified to insert \r\n instead of rn for new line and use annotations.txt instead of annotations.doc)

Code:
.output annotations.txt
.separator \r\n
 SELECT VolumeID, Text, Annotation
 FROM Bookmark;
.exit

I copied sqlite3.exe and the sqlite database from my H2O into the directory and after running, I had the annotations.txt file.

OTOH, my personal preference for extracting annotations which was also somewheres on Mobileread a while back used a single batch file with a rather long command line to do the extract from the database on the Kobo itself, doing some cleanup on the results and leaving them in the same directory as the .cmd file in a file called annotations.html name. Basically, just need extr_annotations.cmd and the sqlite3 executable in a directory and the Kobo ereader connected (for me, the internal storage mounts as drive E: so if yours mounts in a different spot, you'll need to change that ( E:\.kobo to whatever:\.kobo ). The pause at the end of the batch file just keeps the DOS box open so I can see any error messages.

extr_annotations.cmd

Code:
%~dp0SQLite3.exe "E:\.kobo\KoboReader.sqlite" "select (case when datecreated=maxdate then ('<b><i><u>' || replace(volumeid,'file:///mnt/onboard/','') || '</u></i></b><br />') else '' end), max(datecreated, coalesce(datemodified, 0)), text, coalesce(annotation, '') || '<br />' from ( select *, (select max(datecreated) from bookmark where volumeid=bm.volumeid and (text<>'' or annotation<>'')) maxdate from bookmark bm where (text<>'' or annotation<>'') order by maxdate desc, volumeid, datecreated desc )" > "%~dp0annotations.html"

pause
Update:
I shut down my device and turn it on. I followed the steps again and all my notes are exported! Thank you But how do I remove all the |2015-11-29T15:10:28Z| at the beginning of my notes?
================================================== =====
THANK YOU SO MUCH DAVID! The second method works! On my Kobo, I have 202 notes but but I only have 4 notes exported. How so? I am sure I have the latest KoboReader.sqlite as the last modified time is yesterday.
Thanks in advance again!

Last edited by kwokhin; 11-29-2015 at 08:32 PM.
kwokhin is offline   Reply With Quote
Old 11-29-2015, 08:13 PM   #7
kwokhin
Enthusiast
kwokhin began at the beginning.
 
Posts: 46
Karma: 10
Join Date: May 2015
Device: Kobo Glo HD
Quote:
Originally Posted by PeterT View Post
But where did you put them on the PC? The command you have typed says look in the current directory c:\python27 for them.
Update. IT WORKS!!! I don't know why. I just rebooted my device and pull the new(same file size) KoboReader.sqlite and suddenly everything is solved. I'm so gald yet confused haha
================================================== =
I put the KoboReader.sqlite and export_Kobo_notes together in c:\python27.

Last edited by kwokhin; 11-29-2015 at 08:58 PM.
kwokhin is offline   Reply With Quote
Old 11-29-2015, 08:24 PM   #8
kwokhin
Enthusiast
kwokhin began at the beginning.
 
Posts: 46
Karma: 10
Join Date: May 2015
Device: Kobo Glo HD
For those who want to export notes but not quite sure how to do it as suggested by David ( it's not that the explanation is unclear, it's just that I have zero experience with this kind of stuff).

1. Go to http://www.sqlite.org/download.html and download the following zip:
(Sorry I only know how to do it for Windows)
Precompiled Binaries for Windows
sqlite-shell-win32-x86-3090200.zip
(364.10 KiB)

2. Unzip it and go to the folder you just unzipped

3. Inside the folder, create a New Text Document (don't rename it yet)

4. Open the New Text Document and copy the following:

Code:
%~dp0SQLite3.exe "E:\.kobo\KoboReader.sqlite" "select (case when datecreated=maxdate then ('<b><i><u>' || replace(volumeid,'file:///mnt/onboard/','') || '</u></i></b><br />') else '' end), max(datecreated, coalesce(datemodified, 0)), text, coalesce(annotation, '') || '<br />' from ( select *, (select max(datecreated) from bookmark where volumeid=bm.volumeid and (text<>'' or annotation<>'')) maxdate from bookmark bm where (text<>'' or annotation<>'') order by maxdate desc, volumeid, datecreated desc )" > "%~dp0annotations.html"

pause
[/QUOTE]

Be careful with the directory. Match them as below:


5. Click save as and name it extr_annotations.cmd. Plug in your Kobo device.
Make sure you have the following files. I think the New Text Document is not necessary.

7. click extr_annotations and you're done!!

8. There will be a new annotations file

Last edited by kwokhin; 11-29-2015 at 09:07 PM.
kwokhin is offline   Reply With Quote
Old 11-29-2015, 10:52 PM   #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: 37,561
Karma: 149859356
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Good to hear you got it working.
DNSB is offline   Reply With Quote
Old 11-30-2015, 02:06 AM   #10
kwokhin
Enthusiast
kwokhin began at the beginning.
 
Posts: 46
Karma: 10
Join Date: May 2015
Device: Kobo Glo HD
Quote:
Originally Posted by DNSB View Post
Good to hear you got it working.
Thank you so much for your help!! I really appreciate it!
Just one more question, how do I remove all the |2015-11-29T15:10:28Z| at the beginning of my notes?
kwokhin is offline   Reply With Quote
Old 11-30-2015, 09:44 PM   #11
meeera
Grand Sorcerer
meeera ought to be getting tired of karma fortunes by now.meeera ought to be getting tired of karma fortunes by now.meeera ought to be getting tired of karma fortunes by now.meeera ought to be getting tired of karma fortunes by now.meeera ought to be getting tired of karma fortunes by now.meeera ought to be getting tired of karma fortunes by now.meeera ought to be getting tired of karma fortunes by now.meeera ought to be getting tired of karma fortunes by now.meeera ought to be getting tired of karma fortunes by now.meeera ought to be getting tired of karma fortunes by now.meeera ought to be getting tired of karma fortunes by now.
 
meeera's Avatar
 
Posts: 5,674
Karma: 66420972
Join Date: Dec 2011
Location: Australia
Device: Kobo Libra 2, iPadMini4, iPad4, MBP; support other Kobo/Kindles
Doesn't the Kobo Utilities plugin for Calibre do this?
meeera is offline   Reply With Quote
Old 12-01-2015, 12:33 AM   #12
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: 37,561
Karma: 149859356
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by kwokhin View Post
Thank you so much for your help!! I really appreciate it!
Just one more question, how do I remove all the |2015-11-29T15:10:28Z| at the beginning of my notes?
I've never bothered to remove that datestamp since my major use for annotations is correcting errors. If I wanted to, I would probably use Notepad++ with it's regular expression search/replace feature.

As an example to replace a string such as |2015*| in Notepad++, I would use \|2015(.*?)\| as the search string with a blank replace (the backslashes escape the | characters to prevent them being considered special characters).

One note is that I am typing this out of memory. Any possible errors are regretted.
DNSB is offline   Reply With Quote
Old 12-01-2015, 12:51 AM   #13
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: 37,561
Karma: 149859356
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by meeera View Post
Doesn't the Kobo Utilities plugin for Calibre do this?
The last time I tried the backup annotation file option, I got no books with annotation files despite having just made annotations for the 7 ebooks I was attempting to do the backup for so it appears the annotation files are not created for ebooks on the external uSD card. I don't store books on the internal storage so extraction from the database is the route I take.
DNSB is offline   Reply With Quote
Old 12-01-2015, 01:47 AM   #14
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,906
Karma: 47303822
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
I don't suppose I have posted an overview of the methods for getting annotations from the Kobo devices. I would just point to the last time I posted this, but looking at it, it is missing some options and details.

Firstly, I an not happy with any of these methods. They all have limitations or need extra work or something. But, I also don't use any of them much. Most annotations I make are to mark errors in a book or something I want to look up later. Once I have fixed the problem or looked up the info, I delete the annotation. I know that some people want permanent annotations, but I haven't seen anything that comes close to a highlighter pen and a paper book.

Enough preamble, on to the methods...

Firstly, there is the method already discussed: run some SQL against the database and save the output. If you have any SQL skills, this is simple and can be easily customised. There have been also been several scripts posted here that do the same thing.

On the device, you can add "ExportHighlights=true" into the FeatureSettings section of the config file. With this, the long press menu of the book will have an extra option, "Export highlights" (or something like this). Using this will prompt you for a file name and export the annotations to that file in the root directory of the device.

If you are a calibre user, there is "Fetch annotations" (or something like that) on the device menu. This appends the annotations to the comments field of the metadata in the calibre library. It shows the highlighted text plus the annotation.

Again for calibre users, there is the Annotation plugin. Like the built-in calibre function, this fetches the annotations, but it can put them into a custom column. It is also handles them better if you use multiple devices or change them in the calibre library. This supports Kobo and Kindle devices plus some ereader apps. This plugin was created by someone else, but I am maintaining it.

As meera said, my Kobo Utilities plugin has a annotations function. It is basically the calibre "Fetch annotations" but written to a dialog that you can copy the text from. I wrote this before the Annotations plugin existed and do not recommend this. But, if I remove it, someone is sure to complain.

tshering wrote a nice little tool for Windows that extracts the annotations. I don't think it has been updated for a while, but the way annotations are stored hasn't changed, so it should still work.

Lastly, if the epub is on the main memory of the device, there is a file with the annotations in it. This is produced by the Adobe RMSDK side of the reader. It is in the directory "Digital Editions/Annotations". The rest of the path matches the path to the epub and the file has the extension "annot". This is an XML file that can easily be read to see the annotations. And with a little care, can be copied to the PC to use with ADE.

Last edited by davidfor; 12-01-2015 at 06:10 AM. Reason: Fixed link to tshering's tool
davidfor is offline   Reply With Quote
Old 12-01-2015, 05:42 AM   #15
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 3,489
Karma: 2914715
Join Date: Jun 2012
Device: kobo touch
This is the correct link to the nice little tool. And here you can find a screenshot of it.

Last edited by tshering; 12-01-2015 at 05:52 AM.
tshering is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PRS-T1 Annotation Export Limit - Problem Solved BHastings175 Sony Reader 2 06-29-2013 06:53 AM
[KT] Annotation export, citation software, SCIENCE! Pismire Amazon Kindle 0 06-06-2012 12:56 PM
PRS-650 prs 650 notes annotation export pdf bjrnfrdnnd Sony Reader 8 03-10-2011 12:19 AM
export annotation, add note on Neo langmarp BeBook 2 06-28-2010 08:50 AM
annotation export bebook neo langmarp Calibre 0 06-25-2010 11:36 AM


All times are GMT -4. The time now is 09:40 PM.


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