Import-export library/Video: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 77: Line 77:


== Single File ==
== Single File ==
{{warning|'''This method is not the recommended export method'''. Do not use this method unless you have a specific need to do so '''and''' understand the following limitations:<br>
* If you rearrange files and folders after the export, the export still contains the original paths which will be imported creating dead library entries<br>
* Unless you are using Absolute file paths, you cannot build a new library on a different {{kodi}} installation<br>
* URL's to remote artwork are rewritten to the location of the export folder. You will be unable to change artwork using the "Choose Art" option, and if the export folder is deleted (which contains the exported artwork) the artwork will slowly disappear from the library
'''Use the Separate Files method detailed in the previous section'''}}
<gallery mode="packed" widths="500px" heights="283px">
<gallery mode="packed" widths="500px" heights="283px">
File:LibExp06.jpg
File:LibExp06.jpg
</gallery>
</gallery>
{{red|'''Note''': Do not use this option if you have changed, or intend to change, the filenames or paths of your video files after running the Export. Doing so will leave you with a dead library. The data will be imported but Kodi will not be able to locate the moved files. Use the Separate files method instead.}}


This option will export all metadata and all artwork to a single directory, to a location nominated by the user, as follows:
This option will export all metadata and all artwork to a single directory, to a location nominated by the user, as follows:
Line 90: Line 95:
*Subsequent exports are '''full''' exports. They are '''not''' incremental exports.
*Subsequent exports are '''full''' exports. They are '''not''' incremental exports.


{{note|The Single File Export process changes the artwork location URL to the folder location of the export, which causes an issue if you need to refresh the image.}}
{{-}}
{{-}}


Line 129: Line 133:
{{top}}
{{top}}


{{updated|18}}
{{updated|19}}
[[Category:FAQ]]
[[Category:Index]]
[[Category:Guides]]
[[Category:Manual]]
[[Category:Karellen]]
[[Category:Karellen]]
[[Category:Video library]]
[[Category:Video library]]
[[Category:Advanced topics]]
[[Category:First time user]]
[[Category:Quick Start Guide]]

Revision as of 19:19, 12 January 2021

Import-Export Contents
Home icon grey.png   ▶ Video Library ▶ Import Export Library ▶ Video


Watched, PlayCount, ResumePoints

By default Kodi will export all data in the MyVideosxxx.db.

The Watched Status, Play Counts and Resume Points are not imported by default. By pasting the following code to the advancedsettings.xml file, any or all three items can be imported. Do not duplicate the <advancedsettings> tags if you already have the advancedsettings.xml file.

false = Not imported
true = Imported
See also: Advancedsettings.xml
 <advancedsettings>
    <videolibrary>
       <exportautothumbs>false</exportautothumbs>      <!-- Export auto-generated thumbs. Default = false. Change to true to allow export -->
       <importwatchedstate>false</importwatchedstate>  <!-- Import Last Played and Play Counts. Default = false. Change to true to allow import -->
       <importresumepoint>false</importresumepoint>    <!-- Import Resume Points. Default = false. Change to true to allow import -->
    </videolibrary>
 </advancedsettings>


Export

In settings, select Export library as shown in the first image. You will be required to choose the Export method as depicted in the second image.

If you intend to export artwork from cache, be aware of the modifications that Kodi makes to cached artwork. If you have local artwork, do not export artwork.

See: Artwork Cache


Separate Files

This option will export the metadata stored in the database and save it as a nfo file. It will be saved to the same directory where that particular Movie/TV Show/Episode/Music Video is located.

  • After selecting Separate, you will then be asked if you would like to Export thumbnails and fanart?. This will export all artwork that has been cached.
    • Choosing Yes will save a copy of the cached artwork into the Movie, TV Show, TV Show Episode and Music Video directory alongside the video file and the nfo file.
    • Choosing No will not export artwork
Note 1: Exported artwork will use the long name format of <videofilename>-<artworktype>.<ext> eg- Lucy (2014)-poster.jpg
Note 2: If you use local artwork, do not export artwork as your original artwork may be overwritten with an inferior copy or duplicated if you use the short name format.
  • If you selected Yes to the previous option you will be asked Export Actors Thumbs?.
    • Choosing Yes will export a copy of the Actors artwork in a directory named .actors
    • Choosing No will not export a copy of the Actors artwork
  • The final option is Overwrite Old Files?.
    • Choosing Yes will overwrite the existing nfo files and artwork (if selected). This is useful if you have modified your metadata such as changed the artwork, created or modified movie sets, etc. Any movies/tv shows/music videos that were not present since the last Export will have the nfo and artwork exported to their directory.
    • Choosing No will add nfo files and artwork to those movies/tv shows/music videos that do not already have them. eg they are new and added after the last export. If you made changes to a movie/tv show/music video that already has an nfo created, these changes will not be exported.
    • If this is the first time this option has been run and/or you have no nfo files and artwork saved in your movie/tv show/music video directories, both choices will have the same result.

The Export will commence immediately once the final option is selected. An onscreen progress bar will indicate progress.


Single File

Stop hand.png This method is not the recommended export method. Do not use this method unless you have a specific need to do so and understand the following limitations:
  • If you rearrange files and folders after the export, the export still contains the original paths which will be imported creating dead library entries
  • Unless you are using Absolute file paths, you cannot build a new library on a different Kodi installation
  • URL's to remote artwork are rewritten to the location of the export folder. You will be unable to change artwork using the "Choose Art" option, and if the export folder is deleted (which contains the exported artwork) the artwork will slowly disappear from the library

Use the Separate Files method detailed in the previous section


This option will export all metadata and all artwork to a single directory, to a location nominated by the user, as follows:

  • The only option available is the save location which you will be prompted and required to enter
  • Kodi will create a directory in your selected location named xbmc_videodb_yyyy-mm-dd
  • Library metadata will be saved into a single videodb.xml file within that directory
  • Artwork will be saved within multiple sub-directories according to type
  • Subsequent exports will not overwrite existing Single File exports
  • Subsequent exports are full exports. They are not incremental exports.



Import

Which Import method you use will depend on which Export method was used:


Separate Files

If you exported your library using the Export to Separate Files option, then you must use the normal scraping process to re-import the data from the NFO Files. eg Update Library option.

See:Adding or Removing Videos


Single File

If you exported your library using the Export to Single File option, you will need to use this method to import the data as follows


Note: The media Sources must be set before attempting the Import. See: Adding_video_sources

Note: If you have removed media from the library since the export, the media will be imported into the library. You will need to run a Clean Library to remove them.





Return to top