Win export/import of music results in empty music library
#1
I wanted to move from a local database to a mariadb one, so I exported music to one file, quit Kodi, switched advanced settings to point to mariadb IP address, started Kodi, went to media music import and selected the export file for import, saw a flurry of names for a few seconds, and then the music library appeared empty.   The music export lasted a few seconds and created an xml of 18107 lines (no artwork folder like the video export did).   So why the empty music library?   I'm doing a manual scan which is at 35% but I had hoped to avoid this by exporting/importing.  Plus the new manual scan is re-writing my "Recently added albums" history.  The video export/import seemed to work.   Why not the music?
Reply
#2
@ntropy

The music library works differently to the Video library.

The music library is created by scanning the embedded tags of your music files. These need to be scanned into the library first to create the library entries. The file you are trying to import then adds additional information that was scraped.

Moved to Music forum
My Signature
Links to : Forum rules (wiki) | Banned_Add-ons (wiki) | Debug Log (wiki)  
Links to : HOW-TO:Create_Music_Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#3
(2020-02-21, 02:44)Karellen Wrote: @ntropy

The music library works differently to the Video library.

The music library is created by scanning the embedded tags of your music files. These need to be scanned into the library first to create the library entries. The file you are trying to import then adds additional information that was scraped.

Moved to Music forum

So I can still get back my recently added/played albums history from importing after?

I have four folders to scan.  Do I have to scan one and wait until it is finished before initiating the scan command on the second, etc?
Reply
#4
(2020-02-21, 02:49)ntropy Wrote: So I can still get back my recently added/played albums history from importing after?
Yes, once you scan your music files, the Import file will add back your playback history.

(2020-02-21, 02:49)ntropy Wrote: I have four folders to scan.  Do I have to scan one and wait until it is finished before initiating the scan command on the second, etc?
Yes, you need to wait for the first scan to finish before starting the next scan. There is no queue function for scanning.
My Signature
Links to : Forum rules (wiki) | Banned_Add-ons (wiki) | Debug Log (wiki)  
Links to : HOW-TO:Create_Music_Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#5
I just imported after scanning and don't see any music history emerging.
Reply
#6
Are you using v18.2 or later? Was the exported file created by v18.2 or later? Playback history was introduced in v18.2 and is not backwards compatible.

I just noticed that requirement is missing from the wiki page (sorry), but I will add that in now.
My Signature
Links to : Forum rules (wiki) | Banned_Add-ons (wiki) | Debug Log (wiki)  
Links to : HOW-TO:Create_Music_Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#7
(2020-02-21, 04:38)Karellen Wrote: Are you using v18.2 or later? Was the exported file created by v18.2 or later? Playback history was introduced in v18.2 and is not backwards compatible.

I just noticed that requirement is missing from the wiki page (sorry), but I will add that in now.

Exported from 18.5 and imported to 18.5.
Reply
#8
Can you upload that exported file to a file sharing site and provide the link. You can pm me the link if you want to keep it private.

I would like to check for the song data in the file.

Thanks.
My Signature
Links to : Forum rules (wiki) | Banned_Add-ons (wiki) | Debug Log (wiki)  
Links to : HOW-TO:Create_Music_Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#9
Did you actually export the song playback history? You exported to a single file, but what items did you choose to export? If ratings and playcount and last played are not importing that I suspect that you simply didn't export them.

If that is the case and you still have the SQLite db file then you can temporarily point Kodi at that database, export the song playback history (only songs need exporting), point Kodi back at your Mariadb and import your newly created xml file.
Reply
#10
(2020-02-21, 07:33)Karellen Wrote: Can you upload that exported file to a file sharing site and provide the link. You can pm me the link if you want to keep it private.

I would like to check for the song data in the file.

Thanks.

Here's a link: https://wetransfer.com/downloads/866d27e...436/199d89
Reply
#11
(2020-02-21, 11:40)DaveBlake Wrote: Did you actually export the song playback history? You exported to a single file, but what items did you choose to export? If ratings and playcount and last played are not importing that I suspect that you simply didn't export them.

If that is the case and you still have the SQLite db file then you can temporarily point Kodi at that database, export the song playback history (only songs need exporting), point Kodi back at your Mariadb and import your newly created xml file.
I selected everything.  I've been re-organizing music files since the export so the chance for this to work has probably passed.
Reply
#12
(2020-02-24, 20:48)ntropy Wrote: I selected everything.  I've been re-organizing music files since the export so the chance for this to work has probably passed. 
The song playback history import is not filename or folder specific, it uses song properties e.g. title, artist etc., so moved music files are not a problem.

The question is whether the song playback history is in the export file or not. If you can share that file then I will check for you.
Reply
#13
(2020-02-24, 21:13)DaveBlake Wrote:
(2020-02-24, 20:48)ntropy Wrote: I selected everything.  I've been re-organizing music files since the export so the chance for this to work has probably passed. 
The song playback history import is not filename or folder specific, it uses song properties e.g. title, artist etc., so moved music files are not a problem.

The question is whether the song playback history is in the export file or not. If you can share that file then I will check for you. 
Here's the link: https://wetransfer.com/downloads/866d27e...436/199d89
Reply
#14
(2020-02-24, 20:46)ntropy Wrote: Here's a link: https://wetransfer.com/downloads/866d27e...436/199d89
Thanks. The song play count and last played data is definitely there. This is the very first entry from the file you provided...
    <song>
<idsong>132</idsong>
<artistdesc>John Carpenter &amp; Alan Howarth</artistdesc>
<title>“You Are The Duke Of New York”</title>
<track>18</track>
<filename>Escape From New York - Expanded Edition - 18 - “You Are The Duke Of New York”.m4a</filename>
<musicbrainztrackid></musicbrainztrackid>
<idalbum>13</idalbum>
<albumtitle>Escape From New York - Expanded Edition</albumtitle>
<musicbrainzalbumid></musicbrainzalbumid>
<albumartistdesc>John Carpenter &amp; Alan Howarth</albumartistdesc>
<timesplayed>1</timesplayed>
<lastplayed>2019-11-23 03:28:42</lastplayed>
<rating max="10">0.0</rating>
<votes>0</votes>
<userrating max="10">0</userrating>
</song>

I do note that you have no artist or album information exported, just song data. Can you confirm you have scanned your music files into the library of your new setup?
My Signature
Links to : Forum rules (wiki) | Banned_Add-ons (wiki) | Debug Log (wiki)  
Links to : HOW-TO:Create_Music_Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#15
(2020-02-25, 01:30)Karellen Wrote:
(2020-02-24, 20:46)ntropy Wrote: Here's a link: https://wetransfer.com/downloads/866d27e...436/199d89
Thanks. The song play count and last played data is definitely there. This is the very first entry from the file you provided...
 <song>
<idsong>132</idsong>
<artistdesc>John Carpenter &amp; Alan Howarth</artistdesc>
<title>“You Are The Duke Of New York”</title>
<track>18</track>
<filename>Escape From New York - Expanded Edition - 18 - “You Are The Duke Of New York”.m4a</filename>
<musicbrainztrackid></musicbrainztrackid>
<idalbum>13</idalbum>
<albumtitle>Escape From New York - Expanded Edition</albumtitle>
<musicbrainzalbumid></musicbrainzalbumid>
<albumartistdesc>John Carpenter &amp; Alan Howarth</albumartistdesc>
<timesplayed>1</timesplayed>
<lastplayed>2019-11-23 03:28:42</lastplayed>
<rating max="10">0.0</rating>
<votes>0</votes>
<userrating max="10">0</userrating>
</song>

I do note that you have no artist or album information exported, just song data. Can you confirm you have scanned your music files into the library of your new setup?    

I have scanned my music files in the new setup.   The recently played album history in Kodi doesn't have anything played before Feb 20, like this from the export:

<song>
        <idsong>95038</idsong>
        <artistdesc>Miklós Rózsa</artistdesc>
        <title>The Lost Weekend - The Weekend Begins</title>
        <track>65537</track>
        <filename>01 The Lost Weekend - The Weekend Begins.flac</filename>
        <musicbrainztrackid>528048ea-f6f6-4dc3-9e33-0c0e27b03a80</musicbrainztrackid>
        <idalbum>3503</idalbum>
        <albumtitle>Double Indemnity / Killers / Lost Weekend</albumtitle>
        <musicbrainzalbumid>4556e493-5b3d-4f08-abaf-1ed8fc926717</musicbrainzalbumid>
        <albumartistdesc>Miklós Rózsa</albumartistdesc>
        <timesplayed>1</timesplayed>
        <lastplayed>2020-02-20 01:44:57</lastplayed>
        <rating max="10">0.0</rating>
        <votes>0</votes>
        <userrating max="10">0</userrating>
    </song>
Reply



Logout Mark Read Team Forum Stats Members Help
export/import of music results in empty music library0
This forum uses Lukasz Tkacz MyBB addons.