Importing many entries at once from .json #1476
-
Hello, Could you please help me to understand how to import several entries from single .json file so they become separate entries? Each time I try to import file with --format json argument I get AttributeError: 'NoneType' object has no attribute 'import_' as the last line of the error message. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
HI @PavelOsminin, the only import format that jrnl supports is its own jrnl format, so you'll need to transform your JSON file into the jrnl format first before being able to import this. jrnl can export to that format, but it can't import it. |
Beta Was this translation helpful? Give feedback.
-
I have been looking at this myself today, and the following steps have worked well to import a JSON export from DayOne. For example, to import to a test journal (already setup in
For live, omit the test journal name... This will recreate and dedupe any exactly identical entries. However my file has a load of slightly not-identical entries due to some screwup doing a similar exercise to import in DayOne ages ago from yet another journalling app, so there's still a cleanup exercise to perform. The jq filters I'm using are unique to DayOne, so YMMV. The key (for me) is to wrap the date/time in |
Beta Was this translation helpful? Give feedback.
HI @PavelOsminin, the only import format that jrnl supports is its own jrnl format, so you'll need to transform your JSON file into the jrnl format first before being able to import this. jrnl can export to that format, but it can't import it.