XBMC will be renamed to Kodi for v14. Read here for more details

InfoLabels, XBMC databases

From Kodi
(Difference between pages)
Jump to: navigation, search
 
(content)
 
Line 1: Line 1:
 +
{{Cleanup}}
 
{{incomplete}}
 
{{incomplete}}
 +
XBMC uses [http://www.sqlite.org/ SQLite], an open source light-weight SQL database-engine, to store all its library related data ([[Music Library|Music]], [[Video Library|Video]], and Program databases). By default, the database files (*.db) are stored in [[The UserData Folder]], specifically in userdata/Database.
  
===Labels Available In XBMC===
+
In addition to indexing media files when activated by user-selected Content settings, XBMC also puts a video in its database if you change any OSD setting while watching it. Resume points are stored in this database as well.
{| class="wikitable"
+
These entries are added to the database whether the affected video is part of the Video Library or not.
! style="background: lightgrey; width: 150px" | '''infolabels'''
+
 
! style="background: lightgrey; width: 1500px" | '''Definition'''
+
 
|-
+
== Using the Databases ==
|  AudioScrobbler.ConnectState
+
The XBMC databases are automatically maintained whenever you use XBMC. You can activate the most powerful database functionality by setting the Content property on all of your media sources, and using XBMC Library Mode. This view mode allows you to browse your media based on the details available in the databases, rather than using simple folder and filenames for details. You can read more about Library Mode for [[Music Library|Music]] and [[Video Library|Video]] files on their respective pages.
|  Connected to the audioscrobbler
+
 
|-
+
Since XBMC maintains the databases on its own, the only time a developer really needs to access the databases is for display information. The following sections discuss how you can access the information contained in the XBMC databases, and give some brief examples of how to use it.
|  AudioScrobbler.SubmitInterval
+
 
|  Shows next reconnect when submission failed
+
=== Building SQL Queries ===
|-  
+
SQLite queries can be incredibly powerful (and extraordinarily complicated). If you are not already familiar with SQL syntax, it would probably be a good idea to check out a general tutorial, such as [http://www.1keydata.com/sql/sql.html this one].
|  AudioScrobbler.FilesCached
+
 
|  Number of cached songs
+
For most XBMC development projects, you're going to be doing select statements. "Select" is a SQL command used to gather data (in the form of "rows") out of a SQL database. Your select statement will include:
|-
+
 
|  AudioScrobbler.SubmitState
+
* A list of all the data fields (columns in the database table) you want for each row.  
|  Shows time left until the current song is submitted
+
* A list of all the tables you need to get information from
|-
+
* A list of comparisons used to narrow down your results. This last component is optional, but it makes sure your results are relevant and is often used to link database entries across multiple tables.
|  Container.FolderPath
+
 
|  Shows complete path of currently displayed folder
+
Below are a few sample select statements, so you can see how it works.
|-
+
 
|  Container.FolderName
+
This query grabs all of the information for every movie in the Video Library.  
|  Shows top most folder in currently displayed folder
+
<pre><nowiki>select * from movie</nowiki></pre>
|-
+
Note that "*" is used to indicate all fields. Also,there is no "where" clause in this statement, so it returns every row in the table.
|  Container.Viewmode
+
 
|  Returns the current viewmode (list, icons etc.)
+
This query narrows down the results to just those movies released in 2007.  
|-
+
<pre><nowiki>select * from movie where c07 = 2007</nowiki></pre>
|  Container.SortMethod
+
Note that the column containing the movie's release year is labelled simply "c07." The tables further down this page help you find out which columns contain the information you're looking for.  
|  Returns the current sort method (name, year, rating, etc.)
+
 
|-
+
This query example is more semantic. Lists your movies including, in this order, internal ID, internal file ID, rating, movie year, IMDB ID, movie name and movie plot.
| Container.PluginName
+
<pre><nowiki>select idMovie,idFile,c05,c07,c09,c00,c03,c02 from movie;</nowiki></pre>
|  Returns the current plugins base folder name
+
 
|-
+
Now the following query is a bit more complex because it joins 3 movie-related tables ([[movie]], [[files]] and [[path]]) to list a single useful view of your movies. In human language it lists movie ID, movie year, IMDB rating, IMDB ID, movie name and full path of the movie file, ordered by IMDB rating with highest rating appearing first:
|  Container.PluginCategory
+
<pre><nowiki> select idMovie,c07,c05,c09,c00,path.strPath||files.strFilename from movie, files,path where movie.idFile=files.idFile and files.idPath=path.idPath order by c05 desc;</nowiki></pre>
|  Returns the current plugins category (set by the scripter)
+
 
|-
+
You could also use less than or greater than symbols to get newer or older movies.
|  Container.ShowPlot
+
 
|  Returns the TV Show Plot of the current container and can be used at season and episode level
+
This query gets just the path and filename of all of the video files from season two of Chuck.
|-
+
<pre><nowiki></nowiki></pre>
|  Container(id).NumPages
+
If you're not familiar with SQL queries, this query probably looks pretty complicated. It serves as a good demonstration of why there are so many tables in the list below, and how to use them. Many of the elements of a TV show's path and filename and used repeatedly, so SQL allows us to save space and speed up our searches by storing each of those elements just once, in one place, and referencing them repeatedly by the same ID.
|  Number of pages in the container with given id.  If no id is specified it grabs the current container.
+
 
|-
+
In this case, the root path that contains your video files is a long string that repeats at the beginning of many files. The name of a TV series, too, is repeated in every single episode of that series, so it makes the most sense to save the series name once (along with all information relevant to the series). We do that in the table tvshow, and every episode of the TV show can access all of that information using just the TV show's ID.
|  Container(id).NumItems
+
 
|  Number of items in the container with given id.  If no id is specified it grabs the current container.
+
=== Accessing the Databases with a SQLite application ===
|-
+
Database files can be transferred via FTP to a Windows-based computer and edited or analysed with a SQLite graphical client. XBMC's version of the database engine should be compatible with the standard clients such as [http://sqlitebrowser.sourceforge.net SQLiteBrowser] or [http://bobmanc.home.comcast.net/sqlitecc.html SQLiteCC], (more available management-tools can be found in [http://www.sqlite.org/cvstrac/wiki?p=ManagementTools sqlite.org WIKI]).<br />
|  Container(id).CurrentPage
+
We recommend you use [http://www.yunqa.de/delphi/doku.php/products/sqlitespy/index SQLiteSpy version 1.5.2] or higher.
|  Current page in the container with given id. If no id is specified it grabs the current container.
+
* [[HOW-TO: Use your computer to edit XBMC's (SQL) database-files]].
|-
+
 
|  Container(id).Position
+
These applications are generally quite powerful. Once you find one you like, you can easily browse the XBMC databases. This is probably the best way to make modifications to the Video or Music Library.
|  Returns the current focused position of Container (id) as a numeric label.
+
 
|-
+
=== Accessing the Databases with XBMC Python ===
|  Container(id).Totaltime
+
Many Python plugins (and some scripts) can use the information in the XBMC database to offer users additional convenience and functionality. The easiest way to access the XBMC database via XBMC Python is using [[JSON RPC]]
|  Returns the total time of all items in the current container
+
 
|-
+
== The Music Library ==
|  Container(id).ListItem(offset).Label
+
This database contains all information concerning music files that you've added to the Music Library. It is used in the Music portion of XBMC.
|  Shows ListItem.Label for a specific List or Panel Container with a offset ''( eg: Container(50).Listitem(2).Label )''
+
 
|-
+
The music database is stored in userdata/Database/MyMusic7.db
|  Container(id).ListItem(offset).Label2
+
 
|  Shows ListItem.Label2 for a specific List or Panel Container with a offset ''( eg: Container(50).Listitem(-2).Label2 )''
+
=== Views ===
|-
+
Views are standard queries, often long or complicated queries saved in the database for convenience. The views below allow you to easily access all the information about songs and albums in the Music Library, across all the linking tables.
|  Container(id).ListItem(offset).Icon
+
 
|  Shows ListItem.Icon for a specific List or Panel Container with a offset ''( eg: Container(52).Listitem(1).Icon)''
+
==== albumview ====
|-
+
A view that joins album to artist, genre, thumb, and albuminfo.
|  Container(id).ListItem(offset).ActualIcon
+
 
|  Shows ListItem.ActualIcon for a specific List or Panel Container with a offset ''( eg: Container(50).Listitem(0).ActualIcon )''
+
==== artistview ====
|-
+
A view that joins artist to artistinfo.
|  Container(id).ListItem(offset).Thumb
+
 
|  Shows ListItem.Thumb for a specific List or Panel Container with a offset ''( eg: Container(50).Listitem(0).Thumb )''
+
==== songview ====
|-  
+
A view that joins song to album, path, artist, genre, thumb, and karaokedata.
|  Container(id).ListItemNoWrap(offset).Property
+
 
|  Basically returns the same as ListItem(offset) but it won't wrap. That means if the last item of a list is focused, ListItemNoWrap(1) will be empty while ListItem(1) will return the first item of the list. ''Property'' has to be replaced with Label, Label2, Icon etc. ''( eg: Container(50).ListitemNoWrap(1).Plot )''
+
=== Tables ===
|-
+
 
| Container.Property(addoncategory)
+
==== album ====
|  Returns the current add-on category
+
This table contains basic album information.
|-
+
 
|  Container.Property(reponame)
+
{|class="wikitable"
|  Returns the current add-on repository name
+
! Column Name || Data Type || Description
|-
+
|  Control.GetLabel(id)
+
|  Returns the label value or texture name of the control with the given id.
+
|-
+
|  Fanart.Color1
+
|  Returns the first of three colors included in the currently selected '''[[Fanart]]''' theme for the parent TV Show.  Colors are arranged Lightest to Darkest.
+
|-
+
|  Fanart.Color2
+
|  Returns the second of three colors included in the currently selected '''[[Fanart]]''' theme for the parent TV Show.  Colors are arranged Lightest to Darkest.
+
|-
+
|  Fanart.Color3
+
|  Returns the third of three colors included in the currently selected '''[[Fanart]]''' theme for the parent TV Show.  Colors are arranged Lightest to Darkest.
+
|-
+
|  Listitem.Label
+
|  Shows the left label of the currently selected item in a list or thumb control
+
|-
+
|  ListItem.Label2
+
|  Shows the right label of the currently selected item in a list or thumb control
+
|-
+
|  ListItem.Title
+
|  Shows the title of the currently selected song or movie in a list or thumb control
+
|-
+
|  ListItem.OriginalTitle
+
|  Shows the original title of the currently selected movie in a list or thumb control
+
|-
+
|  ListItem.SortLetter
+
|  Shows the first letter of the current file in a list or thumb control
+
|-
+
|  ListItem.TrackNumber
+
|  Shows the track number of the currently selected song in a list or thumb control
+
|-
+
|  ListItem.Artist
+
|  Shows the artist of the currently selected song in a list or thumb control
+
|-
+
|  ListItem.Property(Artist_Born)
+
|  Date of Birth of the currently selected Artist
+
|-
+
|  ListItem.Property(Artist_Died)
+
|  Date of Death of the currently selected Artist
+
|-  
+
|  ListItem.Property(Artist_Formed)
+
|  Formation date of the currently selected Band
+
|-
+
|  ListItem.Property(Artist_Disbanded)
+
|  Disbanding date of the currently selected Band
+
|-  
+
|  ListItem.Property(Artist_YearsActive)
+
|  Years the currently selected artist has been active
+
|-
+
|  ListItem.Property(Artist_Instrument)
+
|  Instruments played by the currently selected artist
+
|-
+
|  ListItem.Property(Artist_Description)
+
|  Shows a biography of the currently selected artist
+
|-  
+
|  ListItem.Property(Artist_Mood)
+
|  Shows the moods of the currently selected artist
+
|-  
+
|  ListItem.Property(Artist_Style)
+
|  Shows the styles of the currently selected artist
+
|-
+
|  ListItem.Property(Artist_Genre)
+
|  Shows the genre of the currently selected artist
+
|-
+
|  ListItem.Album
+
|  Shows the album of the currently selected song in a list or thumb control
+
|-
+
|  ListItem.Property(Album_Mood)
+
|  Shows the moods of the currently selected Album
+
|-
+
|  ListItem.Property(Album_Style)
+
|  Shows the styles of the currently selected Album
+
|-
+
|  ListItem.Property(Album_Theme)
+
|  Shows the themes of the currently selected Album
+
|-
+
|  ListItem.Property(Album_Type)
+
|  Shows the Album Type (e.g. compilation, enhanced, explicit lyrics) of the currently selected Album
+
|-
+
|  ListItem.Property(Album_Label)
+
|  Shows the record label of the currently selected Album
+
|-
+
|  ListItem.Property(Album_Description)
+
|  Shows a review of the currently selected Album
+
|-
+
|  ListItem.DiscNumber
+
|  Shows the disc number of the currently selected song in a list or thumb control
+
|-
+
|  ListItem.Year
+
|  Shows the year of the currently selected song, album or movie in a list or thumb control
+
|-
+
|  ListItem.Premiered
+
|  Shows the release/aired date of the currently selected episode, show or movie in a list or thumb control
+
|-
+
|  ListItem.Genre
+
|  Shows the genre of the currently selected song, album or movie in a list or thumb control
+
|-
+
|  ListItem.Director
+
|  Shows the director of the currently selected movie in a list or thumb control
+
|-
+
|  ListItem.Country
+
|  Shows the production country of the currently selected movie in a list or thumb control
+
|-
+
|  ListItem.Episode
+
|  Shows the episode number value for the currently selected episode. It also shows the number of total, watched or unwatched episodes for the currently selected tvshow or season, based on the the current watched filter.
+
|-
+
|  ListItem.Season
+
|  Shows the season value for the currently selected tvshow
+
|-
+
|  ListItem.TVShowTitle
+
|  Shows the name value for the currently selected tvshow in the season and episode depth of the video library
+
|-
+
|  ListItem.Property(TotalSeasons)
+
|  Shows the total number of seasons for the currently selected tvshow
+
|-
+
|  ListItem.Property(TotalEpisodes)
+
|  Shows the total number of episodes for the currently selected tvshow or season
+
|-
+
|  ListItem.Property(WatchedEpisodes)
+
|  Shows the number of watched episodes for the currently selected tvshow or season
+
|-
+
| ListItem.Property(UnWatchedEpisodes)
+
| Shows the number of unwatched episodes for the currently selected tvshow or season
+
|-
+
| ListItem.Property(NumEpisodes)
+
|  Shows the number of total, watched or unwatched episodes for the currently selected tvshow or season, based on the the current watched filter.
+
 
|-
 
|-
| ListItem.PictureAperture
+
|idAlbum || integer || Primary Key
| Shows the F-stop used to take the selected picture. This is the value of the EXIF FNumber tag (hex code 0x829D).
+
 
|-
 
|-
| ListItem.PictureAuthor
+
|strAlbum || varchar(256) || Album Name
| {{Gotham note |Shows the name of the person involved in writing about the selected picture. This is the value of the IPTC Writer tag (hex code 0x7A).}}
+
 
|-
 
|-
| ListItem.PictureByline
+
|strArtists || text|| Artist Name
| {{Gotham note |Shows the name of the person who created the selected picture.  This is the value of the IPTC Byline tag (hex code 0x50).}}
+
 
|-
 
|-
| ListItem.PictureBylineTitle
+
|strGenres || text || Album Genre
| {{Gotham note |Shows the title of the person who created the selected picture. This is the value of the IPTC BylineTitle tag (hex code 0x55).}}
+
 
|-
 
|-
| ListItem.PictureCamMake
+
|iYear || integer || Album Year
| Shows the manufacturer of the camera used to take the selected picture. This is the value of the EXIF Make tag (hex code 0x010F).
+
 
|-
 
|-
| ListItem.PictureCamModel
+
|idThumb || integer || Foreign key to [[The XBMC Database#thumb(music)|thumb table]]
| Shows the manufacturer's model name or number of the camera used to take the selected picture. This is the value of the EXIF Model tag (hex code 0x0110).
+
 
|-
 
|-
| ListItem.PictureCaption
+
|bCompilation || integer || [unknown]
| Shows a description of the selected picture. This is the value of the IPTC Caption tag (hex code 0x78).
+
|}
 +
 
 +
==== album_artist ====
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| ListItem.PictureCategory
+
|idArtist || integer || Primary Key
| {{Gotham note |Shows the subject of the selected picture as a category code. This is the value of the IPTC Category tag (hex code 0x0F).}}
+
 
|-
 
|-
| ListItem.PictureCCDWidth
+
|idAlbum || integre || [unknown]
| {{Gotham note |Shows the width of the CCD in the camera used to take the selected picture. This is calculated from three EXIF tags (0xA002 * 0xA210 / 0xA20e).}}
+
 
|-
 
|-
| ListItem.PictureCity
+
|boolFeatured || integer || [unknown]
| {{Gotham note |Shows the city where the selected picture was taken. This is the value of the IPTC City tag (hex code 0x5A).}}
+
 
|-
 
|-
| ListItem.PictureColour
+
|iOrder || integer || [unknown]
| {{Gotham note |Shows whether the selected picture is "Colour" or "Black and White".}}
+
|}
 +
 
 +
==== album_genre ====
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| ListItem.PictureComment
+
|idGenre || integer || Primary Key
| Shows a description of the selected picture. This is the value of the EXIF User Comment tag (hex code 0x9286). This is the same value as Slideshow.SlideComment.
+
 
|-
 
|-
| ListItem.PictureCopyrightNotice
+
|idAlbum || integer || [unknown]
| {{Gotham note |Shows the copyright notice of the selected picture. This is the value of the IPTC Copyright tag (hex code 0x74).}}
+
 
|-
 
|-
| ListItem.PictureCountry
+
|iOrder || integer || [unknown]
| {{Gotham note |Shows the full name of the country where the selected picture was taken. This is the value of the IPTC CountryName tag (hex code 0x65).}}
+
|}
 +
 
 +
==== albuminfo ====
 +
This table contains additional information about an album, such as Rating, Moods, Styles, Reviews, Image URL, and type.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| ListItem.PictureCountryCode
+
|idAlbumInfo || integer || Primary Key
| {{Gotham note |Shows the country code of the country where the selected picture was taken. This is the value of the IPTC CountryCode tag (hex code 0x64).}}
+
 
|-
 
|-
| ListItem.PictureCredit
+
|idAlburm || integer || Foreign key
| {{Gotham note |Shows who provided the selected picture. This is the value of the IPTC Credit tag (hex code 0x6E).}}
+
 
|-
 
|-
| ListItem.PictureDate
+
|iYear || integer || Album Year
| Shows the localized date of the selected picture. The short form of the date is used. The value of the EXIF DateTimeOriginal tag (hex code 0x9003) is preferred. If the DateTimeOriginal tag is not found, the value of DateTimeDigitized (hex code 0x9004) or of DateTime (hex code 0x0132) might be used.
+
|-
+
| ListItem.PictureDatetime
+
| Shows the date/timestamp of the selected picture. The localized short form of the date and time is used. The value of the EXIF DateTimeOriginal tag (hex code 0x9003) is preferred. If the DateTimeOriginal tag is not found, the value of DateTimeDigitized (hex code 0x9004) or of DateTime (hex code 0x0132) might be used.
+
 
|-
 
|-
| ListItem.PictureDesc
+
|strMoods || text || [unknown]
| Shows a short description of the selected picture. The SlideComment, EXIFComment, or Caption values might contain a longer description. This is the value of the EXIF ImageDescription tag (hex code 0x010E).
+
 
|-
 
|-
| ListItem.PictureDigitalZoom
+
|strStyles || text || [unknown]
| {{Gotham note |Shows the digital zoom ratio when the selected picture was taken. This is the value of the EXIF DigitalZoomRatio tag (hex code 0xA404).}}
+
 
|-
 
|-
| ListItem.PictureExpMode
+
|strThemes || text || [unknown]
| Shows the exposure mode of the selected picture. The possible values are "Automatic", "Manual", and "Auto bracketing". This is the value of the EXIF ExposureMode tag (hex code 0xA402).
+
 
|-
 
|-
| ListItem.PictureExposure
+
|strReview || text || [unknown]
| {{Gotham note |Shows the class of the program used by the camera to set exposure when the selected picture was taken. Values include "Manual", "Program (Auto)", "Aperture priority (Semi-Auto)", "Shutter priority (semi-auto)", etc. This is the value of the EXIF ExposureProgram tag (hex code 0x8822).}}
+
 
|-
 
|-
| ListItem.PictureExposureBias
+
|strImage || text || [unknown]
| {{Gotham note |Shows the exposure bias of the selected picture. Typically this is a number between -99.99 and 99.99. This is the value of the EXIF ExposureBiasValue tag (hex code 0x9204).}}
+
 
|-
 
|-
| ListItem.PictureExpTime
+
|strLabel || text || [unknown]
| Shows the exposure time of the selected picture, in seconds. This is the value of the EXIF ExposureTime tag (hex code 0x829A). If the ExposureTime tag is not found, the ShutterSpeedValue tag (hex code 0x9201) might be used.
+
 
|-
 
|-
| ListItem.PictureFlashUsed
+
|strType || text || [unknown]
| {{Gotham note |Shows the status of flash when the selected picture was taken. The value will be either "Yes" or "No", and might include additional information. This is the value of the EXIF Flash tag (hex code 0x9209).}}
+
 
|-
 
|-
| ListItem.PictureFocalLen
+
|iRating || integer || [unknown]
| Shows the lens focal length of the selected picture
+
|}
 +
 
 +
==== albuminfosong ====
 +
This table links songs to albums and stores the duration of each track.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| ListItem.PictureFocusDist
+
|idAlbumInfoSong || integer || Primary Key
| Shows the focal length of the lens, in mm. This is the value of the EXIF FocalLength tag (hex code 0x920A).
+
 
|-
 
|-
| ListItem.PictureGPSLat
+
|idAlbumInfo || integer || Foreign Key
| Shows the latitude where the selected picture was taken (degrees, minutes, seconds North or South). This is the value of the EXIF GPSInfo.GPSLatitude and GPSInfo.GPSLatitudeRef tags.
+
 
|-
 
|-
| ListItem.PictureGPSLon
+
|iTrack || integer || [unknown]
| Shows the longitude where the selected picture was taken (degrees, minutes, seconds East or West). This is the value of the EXIF GPSInfo.GPSLongitude and GPSInfo.GPSLongitudeRef tags.
+
 
|-
 
|-
| ListItem.PictureGPSAlt
+
|strTitle || text || [unknown]
| Shows the altitude in meters where the selected picture was taken. This is the value of the EXIF GPSInfo.GPSAltitude tag.
+
 
|-
 
|-
| ListItem.PictureHeadline
+
|iDuration || integer || [unknown]
| {{Gotham note |Shows a synopsis of the contents of the selected picture. This is the value of the IPTC Headline tag (hex code 0x69).}}
+
|}
 +
 
 +
==== art ====
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| {{Gotham note |ListItem.PictureImageType
+
|art_id || integer || Primary Key
| {{Gotham note |Shows the color components of the selected picture. This is the value of the IPTC ImageType tag (hex code 0x82).}}
+
 
|-
 
|-
| {{Gotham note |ListItem.PictureIPTCDate
+
|media_id || integer || [unknown]
| {{Gotham note |Shows the date when the intellectual content of the selected picture was created, rather than when the picture was created. This is the value of the IPTC DateCreated tag (hex code 0x37).}}
+
 
|-
 
|-
| {{Gotham note |ListItem.PictureIPTCTime
+
|media_type || text || [unknown]
| {{Gotham note |Shows the time when the intellectual content of the selected picture was created, rather than when the picture was created. This is the value of the IPTC TimeCreated tag (hex code 0x3C).}}
+
 
|-
 
|-
| ListItem.PictureISO
+
|type || text || [unknown]
| Shows the ISO speed of the camera when the selected picture was taken. This is the value of the EXIF ISOSpeedRatings tag (hex code 0x8827).
+
 
|-
 
|-
| ListItem.PictureKeywords
+
|url || text || [unknown]
| Shows keywords assigned to the selected picture. This is the value of the IPTC Keywords tag (hex code 0x19).
+
|}
 +
 
 +
==== artist ====
 +
This table stores the name of each artist.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| ListItem.PictureLightSource
+
|idArtist || integer || Primary Key
| {{Gotham note |Shows the kind of light source when the picture was taken. Possible values include "Daylight", "Fluorescent", "Incandescent", etc. This is the value of the EXIF LightSource tag (hex code 0x9208).}}
+
 
|-
 
|-
| ListItem.PictureLongDate
+
|strArtist || varchar(256) || [unknown]
| {{Gotham note |Shows only the localized date of the selected picture. The long form of the date is used. The value of the EXIF DateTimeOriginal tag (hex code 0x9003) is preferred. If the DateTimeOriginal tag is not found, the value of DateTimeDigitized (hex code 0x9004) or of DateTime (hex code 0x0132) might be used.}}
+
|}
 +
 
 +
==== artistinfo ====
 +
This tables stores relevant information about each artist, such as when they were born, Fan Art URL's, biographical information, etc.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| ListItem.PictureLongDatetime
+
|idArtistInfo || integer || Primary Key
| {{Gotham note |Shows the date/timestamp of the selected picture. The localized long form of the date and time is used. The value of the EXIF DateTimeOriginal tag (hex code 0x9003) is preferred. if the DateTimeOriginal tag is not found, the value of DateTimeDigitized (hex code 0x9004) or of DateTime (hex code 0x0132) might be used.}}
+
 
|-
 
|-
| ListItem.PictureMeteringMode
+
|idArtist || integer || Foreign Key
| {{Gotham note |Shows the metering mode used when the selected picture was taken. The possible values are "Center weight", "Spot", or "Matrix". This is the value of the EXIF MeteringMode tag (hex code 0x9207).}}
+
 
|-
 
|-
| ListItem.PictureObjectName
+
|strBorn || text || [unknown]
| {{Gotham note |Shows a shorthand reference for the selected picture. This is the value of the IPTC ObjectName tag (hex code 0x05).}}
+
 
|-
 
|-
| ListItem.PictureOrientation
+
|strFormed || text || [unknown]
| {{Gotham note |Shows the orientation of the selected picture. Possible values are "Top Left", "Top Right", "Left Top", "Right Bottom", etc. This is the value of the EXIF Orientation tag (hex code 0x0112).}}
+
|-   
+
| ListItem.PicturePath
+
|  Shows the filename and path of the selected picture
+
 
|-
 
|-
| ListItem.PictureProcess
+
|strGenres || text || [unknown]
| {{Gotham note |Shows the process used to compress the selected picture}}
+
 
|-
 
|-
| ListItem.PictureReferenceService
+
|strMoods || text || [unknown]
| {{Gotham note |Shows the Service Identifier of a prior envelope to which the selected picture refers. This is the value of the IPTC ReferenceService tag (hex code 0x2D).}}
+
|-
+
| ListItem.PictureResolution
+
|  Shows the dimensions of the selected picture
+
 
|-
 
|-
| ListItem.PictureSource
+
|strStyles || text || [unknown]
| {{Gotham note |Shows the original owner of the selected picture. This is the value of the IPTC Source tag (hex code 0x73).}}
+
 
|-
 
|-
| ListItem.PictureSpecialInstructions
+
|strInstruments || text || [unknown]
| {{Gotham note |Shows other editorial instructions concerning the use of the selected picture. This is the value of the IPTC SpecialInstructions tag (hex code 0x28).}}
+
 
|-
 
|-
| ListItem.PictureState
+
|strBiography || text || [unknown]
| {{Gotham note |Shows the State/Province where the selected picture was taken. This is the value of the IPTC ProvinceState tag (hex code 0x5F).}}
+
 
|-
 
|-
| ListItem.PictureSublocation
+
|strDied || text || [unknown]
| {{Gotham note |Shows the location within a city where the selected picture was taken - might indicate the nearest landmark. This is the value of the IPTC SubLocation tag (hex code 0x5C).}}
+
 
|-
 
|-
| ListItem.PictureSupplementalCategories
+
|strDisbanded || text || [unknown]
| {{Gotham note |Shows supplemental category codes to further refine the subject of the selected picture. This is the value of the IPTC SuppCategory tag (hex code 0x14).}}
+
 
|-
 
|-
| ListItem.PictureTransmissionReference
+
|strYearsActive || text || [unknown]
| {{Gotham note |Shows a code representing the location of original transmission of the selected picture. This is the value of the IPTC TransmissionReference tag (hex code 0x67).}}
+
 
|-
 
|-
| ListItem.PictureUrgency
+
|strImage || text || [unknown]
| {{Gotham note |Shows the urgency of the selected picture. Values are 1-9. The "1" is most urgent. Some image management programs use urgency to indicate picture rating, where urgency "1" is 5 stars and urgency "5" is 1 star. Urgencies 6-9 are not used for rating. This is the value of the IPTC Urgency tag (hex code 0x0A).}}
+
 
|-
 
|-
| ListItem.PictureWhiteBalance
+
|strFanart || text || [unknown]
| {{Gotham note |Shows the white balance mode set when the selected picture was taken. The possible values are "Manual" and "Auto". This is the value of the EXIF WhiteBalance tag (hex code 0xA403).}}
+
|}
|-
+
 
| ListItem.FileName
+
==== content ====
|  Shows the filename of the currently selected song or movie in a list or thumb control
+
This table is related to the scraper.
|-
+
{|class="wikitable"
|  ListItem.Path
+
! Column Name || Data Type || Description
|  Shows the complete path of the currently selected song or movie in a list or thumb control
+
|-
+
|  ListItem.FolderName
+
|  Shows top most folder of the path of the currently selected song or movie in a list or thumb control
+
|-
+
|  ListItem.FileNameAndPath
+
|  Shows the full path with filename of the currently selected song or movie in a list or thumb control
+
|-
+
|  ListItem.FileExtension
+
|  Shows the file extension (without leading dot) of the currently selected item in a list or thumb control
+
|-
+
|  ListItem.Date
+
|  Shows the file date of the currently selected song or movie in a list or thumb control
+
|-
+
|  ListItem.DateAdded
+
|  Shows the date the currently selected item was added to the library
+
|-
+
|  ListItem.Size
+
|  Shows the file size of the currently selected song or movie in a list or thumb control
+
|-
+
|  ListItem.Rating
+
|  Shows the IMDB rating of the currently selected movie in a list or thumb control
+
|-
+
|  ListItem.Votes
+
|  Shows the IMDB votes of the currently selected movie in a list or thumb control '''([[:Category:Gotham feature|Future Gotham addition]])'''
+
|-
+
|  ListItem.RatingAndVotes
+
|  Shows the IMDB rating and votes of the currently selected movie in a list or thumb control
+
|-
+
|  ListItem.Mpaa
+
|  Show the MPAA rating of the currently selected movie in a list or thumb control
+
|-
+
|  ListItem.ProgramCount
+
| Shows the number of times an xbe has been run from "my programs"
+
|-
+
| ListItem.Duration
+
| Shows the song or movie duration of the currently selected movie in a list or thumb control
+
 
|-
 
|-
| ListItem.DBID
+
|strPath || text || [unknown]
| Shows the database id of the currently selected listitem in a list or thumb control
+
 
|-
 
|-
| ListItem.Cast
+
|strScraperPath || text || [unknown]
| Shows a concatenated string of cast members of the currently selected movie, for use in dialogvideoinfo.xml
+
|-
+
| ListItem.CastAndRole
+
| Shows a concatenated string of cast members and roles of the currently selected movie, for use in dialogvideoinfo.xml
+
|-
+
|  ListItem.Studio
+
|  Studio of current selected Music Video in a list or thumb control
+
|-
+
|  ListItem.Trailer
+
|  Shows the full trailer path with filename of the currently selected movie in a list or thumb control
+
|-
+
|  ListItem.Writer
+
|  Name of Writer of current Video in a list or thumb control
+
|-
+
|  ListItem.Tagline
+
|  Small Summary of current Video in a list or thumb control
+
|-
+
|  ListItem.PlotOutline
+
|  Small Summary of current Video in a list or thumb control
+
|-
+
|  ListItem.Plot
+
|  Complete Text Summary of Video in a list or thumb control
+
|-
+
|  ListItem.PercentPlayed
+
|  Returns percentage value [0-100] of how far the selected video has been played
+
|-
+
|  ListItem.LastPlayed
+
|  Last play date of Video in a list or thumb control
+
 
|-
 
|-
| ListItem.PlayCount
+
|strContent || text || [unknown]
| Playcount of Video in a list or thumb control
+
 
|-
 
|-
| ListItem.StartTime
+
|strSettings || text || [unknown]
| Start time of current selected TV programme in a list or thumb control
+
|}
|-
+
 
| ListItem.EndTime
+
==== discography ====
| End time of current selected TV programme in a list or thumb control
+
Links albums to artists with the year produced.
|-
+
 
|  ListItem.StartDate
+
==== exartistablum ====
|  Start date of current selected TV programme in a list or thumb control
+
Links artists to albums
|-
+
 
|  ListItem.Date
+
==== exartistsong ====
|  Day, start time and end time of current selected TV programme in a list or thumb control
+
Links artists to songs
|-
+
 
|  ListItem.ChannelNumber
+
==== exgenrealbum ====
|  Number of current selected TV channel in a list or thumb control
+
Links genres to albums
|-
+
 
| ListItem.ChannelName
+
==== exgenresong ====
| Name of current selected TV channel in a list or thumb control
+
Links genres to songs
 +
 
 +
==== genre(music) ====
 +
This table contains genre titles.
 +
 
 +
==== karaokedata ====
 +
This table contains karaoke specific information for certain songs
 +
 
 +
==== path(music) ====
 +
This table contains paths and hashes of files in the Music Database.
 +
 
 +
==== song ====
 +
This table contains song information such as Name, Track Title, MusicBrainz information, times played, last played, rating, etc.
 +
 
 +
==== thumb ====
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| ListItem.VideoCodec
+
|idThumb || integer || Primary Key
| Shows the video codec of the currently selected video (common values: 3iv2, avc1, div2, div3, divx, divx 4, dx50, flv, h264, microsoft, mp42, mp43, mp4v, mpeg1video, mpeg2video, mpg4, rv40, svq1, svq3, theora, vp6f, wmv2, wmv3, wvc1, xvid)
+
|-
+
| ListItem.VideoResolution
+
| Shows the resolution of the currently selected video (possible values: 480, 576, 540, 720, 1080). Note that 540 usually means a widescreen format (around 960x540) while 576 means PAL resolutions (normally 720x576), therefore 540 is actually better resolution than 576.
+
|-
+
|  ListItem.VideoAspect
+
|  Shows the aspect ratio of the currently selected video (possible values: 1.33, 1.66, 1.78, 1.85, 2.20, 2.35)
+
|-
+
|  ListItem.AudioCodec
+
|  Shows the audio codec of the currently selected video (common values: aac, ac3, cook, dca, dtshd_hra, dtshd_ma, eac3, mp1, mp2, mp3, pcm_s16be, pcm_s16le, pcm_u8, truehd, vorbis, wmapro, wmav2)
+
|-
+
|  ListItem.AudioChannels
+
|  Shows the number of audio channels of the currently selected video (possible values: 0, 1, 2, 4, 5, 6, 8)
+
|-
+
|  ListItem.AudioLanguage
+
|  Shows the audio language of the currently selected video (returns an ISO 639-2 three character code, e.g. eng, epo, deu)
+
|-
+
|  ListItem.SubtitleLanguage
+
|  Shows the subtitle language of the currently selected video (returns an ISO 639-2 three character code, e.g. eng, epo, deu)
+
|-
+
|  ListItem.Property(Addon.Name)
+
|  Shows the name of the currently selected addon
+
|-
+
|  ListItem.Property(Addon.Version)
+
|  Shows the version of the currently selected addon
+
|-
+
|  ListItem.Property(Addon.Summary)
+
|  Shows a short description of the currently selected addon
+
|-
+
|  ListItem.Property(Addon.Description)
+
|  Shows the full description of the currently selected addon
+
|-
+
|  ListItem.Property(Addon.Type)
+
|  Shows the type (screensaver, script, skin, etc...) of the currently selected addon
+
|-
+
|  ListItem.Property(Addon.Creator)
+
|  Shows the name of the author the currently selected addon
+
|-
+
|  ListItem.Property(Addon.Disclaimer)
+
|  Shows the disclaimer of the currently selected addon
+
|-
+
|  ListItem.Property(Addon.Changelog)
+
|  Shows the changelog of the currently selected addon
+
|-
+
|  ListItem.Property(Addon.ID)
+
|  Shows the identifier of the currently selected addon
+
|-
+
|  ListItem.Property(Addon.Status)
+
|  Shows the status of the currently selected addon
+
|-
+
|  ListItem.Property(Addon.Broken)
+
|  Shows a message when the addon is marked as broken in the repo
+
|-
+
|  ListItem.Property(Addon.Path)
+
|  Shows the path of the currently selected addon
+
|- {{frodo row}}
+
|  ListItem.StartTime
+
|  Start time of the selected item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.EndTime
+
|  End time of the selected item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.StartDate
+
|  Start date of the selected item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.EndDate
+
|  End date of the selected item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.NextTitle
+
|  Title of the next item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.NextGenre
+
|  Genre of the next item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.NextPlot
+
|  Plot of the next item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.NextPlotOutline
+
|  Plot outline of the next item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.NextStartTime
+
|  Start time of the next item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.NextEndTime
+
|  End of the next item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.NextStartDate
+
|  Start date of the next item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.NextEndDate
+
|  End date of the next item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.ChannelName
+
|  Channelname of the selected item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.ChannelNumber
+
|  Channel number of the selected item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.ChannelGroup
+
|  Channel group of the selected item (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.Progress
+
|  Part of the programme that's been played (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|-
+
|  MusicPlayer.Title
+
|  Title of the currently playing song,  also available are "MusicPlayer.offset(number).Title" offset is relative to the current playing item and "MusicPlayer.Position(number).Title" position is relative to the start of the playlist
+
|-
+
|  MusicPlayer.Album
+
|  Album from which the current song is from,  also available are "MusicPlayer.offset(number).Album" offset is relative to the current playing item and "MusicPlayer.Position(number).Album" position is relative to the start of the playlist
+
|-
+
|  MusicPlayer.Property(Album_Mood)
+
|  Shows the moods of the currently playing Album
+
|-
+
|  MusicPlayer.Property(Album_Style)
+
|  Shows the styles of the currently playing Album
+
|-
+
|  MusicPlayer.Property(Album_Theme)
+
|  Shows the themes of the currently playing Album
+
|-
+
|  MusicPlayer.Property(Album_Type)
+
|  Shows the Album Type (e.g. compilation, enhanced, explicit lyrics) of the currently playing Album
+
|-
+
|  MusicPlayer.Property(Album_Label)
+
|  Shows the record label of the currently playing Album
+
|-
+
|  MusicPlayer.Property(Album_Description)
+
|  Shows a review of the currently playing Album
+
|-
+
|  MusicPlayer.Artist
+
|  Artist(s) of current song,  also available are "MusicPlayer.offset(number).Artist" offset is relative to the current playing item and "MusicPlayer.Position(number).Artist" position is relative to the start of the playlist
+
|-
+
|  MusicPlayer.Property(Artist_Born)
+
|  Date of Birth of the currently playing Artist
+
|-
+
|  MusicPlayer.Property(Artist_Died)
+
|  Date of Death of the currently playing Artist
+
|-
+
|  MusicPlayer.Property(Artist_Formed)
+
|  Formation date of the currently playing Artist/Band
+
|-
+
|  MusicPlayer.Property(Artist_Disbanded)
+
|  Disbanding date of the currently playing Artist/Band
+
|-
+
|  MusicPlayer.Property(Artist_YearsActive)
+
|  Years the currently Playing artist has been active
+
|-
+
|  MusicPlayer.Property(Artist_Instrument)
+
|  Instruments played by the currently playing artist
+
|-
+
|  MusicPlayer.Property(Artist_Description)
+
|  Shows a biography of the currently playing artist
+
|-
+
|  MusicPlayer.Property(Artist_Mood)
+
|  Shows the moods of the currently playing artist
+
|-
+
|  MusicPlayer.Property(Artist_Style)
+
|  Shows the styles of the currently playing artist
+
|-
+
|  MusicPlayer.Property(Artist_Genre)
+
|  Shows the genre of the currently playing artist
+
|-
+
|  MusicPlayer.Genre
+
|  Genre(s) of current song,  also available are "MusicPlayer.offset(number).Genre" offset is relative to the current playing item and "MusicPlayer.Position(number).Genre" position is relative to the start of the playlist
+
|-
+
|  MusicPlayer.Lyrics
+
|  Lyrics of current song stored in ID tag info
+
|-
+
|  MusicPlayer.Year
+
|  Year of release of current song,  also available are "MusicPlayer.offset(number).Year" offset is relative to the current playing item and "MusicPlayer.Position(number).Year" position is relative to the start of the playlist
+
|-
+
|  MusicPlayer.Rating
+
|  Numeric Rating of current song,  also available are "MusicPlayer.offset(number).Rating" offset is relative to the current playing item and "MusicPlayer.Position(number).Rating" position is relative to the start of the playlist
+
|-
+
|  MusicPlayer.DiscNumber
+
|  Disc Number of current song stored in ID tag info,  also available are "MusicPlayer.offset(number).DiscNumber" offset is relative to the current playing item and "MusicPlayer.Position(number).DiscNumber" position is relative to the start of the playlist
+
|-
+
|  MusicPlayer.Comment
+
|  Comment of current song stored in ID tag info,  also available are "MusicPlayer.offset(number).Comment" offset is relative to the current playing item and "MusicPlayer.Position(number).Comment" position is relative to the start of the playlist
+
|-
+
|  MusicPlayer.Time
+
|  Current time in song
+
|-
+
|  MusicPlayer.TimeRemaining
+
|  Current remaining time in song
+
|-
+
|  MusicPlayer.TimeSpeed
+
|  Both the time and the playspeed formatted up. eg 1:23 (2x)
+
|-
+
|  MusicPlayer.TrackNumber
+
|  Track number of current song,  also available are "MusicPlayer.offset(number).TrackNumber" offset is relative to the current playing item and "MusicPlayer.Position(number).TrackNumber" position is relative to the start of the playlist
+
|-
+
|  MusicPlayer.Duration
+
|  Duration of current song,  also available are "MusicPlayer.offset(number).Duration" offset is relative to the current playing item and "MusicPlayer.Position(number).Duration" position is relative to the start of the playlist
+
|-
+
|  MusicPlayer.BitRate
+
|  Bitrate of current song
+
|-
+
|  MusicPlayer.Channels
+
|  Number of channels of current song
+
|-
+
|  MusicPlayer.BitsPerSample
+
|  Number of bits per sample of current song
+
|-
+
|  MusicPlayer.SampleRate
+
|  Samplerate of current song
+
|-
+
|  MusicPlayer.Codec
+
|  Codec of current song
+
|-
+
|  MusicPlayer.PlaylistPosition
+
|  Position of the current song in the current music playlist
+
|-
+
|  MusicPlayer.PlaylistLength
+
|  Total size of the current music playlist
+
|- {{frodo row}}
+
|  MusicPlayer.ChannelName
+
|  Channel name of the radio programme that's currently playing (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  MusicPlayer.ChannelNumber
+
|  Channel number of the radio programme that's currently playing (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  MusicPlayer.ChannelGroup
+
|  Channel group of  of the radio programme that's currently playing (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|-
+
|  MusicPartyMode.SongsPlayed
+
|  Number of songs played during Party Mode
+
|-
+
|  MusicPartyMode.MatchingSongs
+
|  Number of songs available to Party Mode
+
|-
+
|  MusicPartyMode.MatchingSongsPicked
+
|  Number of songs picked already for Party Mode
+
|-
+
|  MusicPartyMode.MatchingSongsLeft
+
|  Number of songs left to be picked from for Party Mode
+
|-
+
|  MusicPartyMode.RelaxedSongsPicked
+
|  Not currently used
+
|-
+
|  MusicPartyMode.RandomSongsPicked
+
|  Number of unique random songs picked during Party Mode
+
|-
+
|  Network.IPAddress
+
|  The system's IP Address (formatted as IP: <ipaddress>)
+
|-
+
|  Network.MacAddress
+
|  The system's  mac address
+
|-
+
|  Network.IsDHCP
+
|  Network type is DHCP or FIXED
+
|-
+
|  Network.LinkState
+
|  Network linkstate e.g. 10mbit/100mbit etc.
+
|-
+
|  Network.SubnetAddress
+
|  Network subnet address
+
|-
+
|  Network.GatewayAddress
+
|  Network gateway address
+
|-
+
|  Network.DHCPAddress
+
|  DHCP ip address
+
|-
+
|  Network.DNS1Address
+
|  Network dns 1 address
+
|-
+
|  Network.DNS2Address
+
|  Network dns 2 address
+
|-
+
|  Player.FinishTime
+
|  Time playing media will end
+
|-
+
|  Player.Chapter
+
|  Current chapter of current playing media
+
|-
+
|  Player.ChapterCount
+
|  Total number of chapters of current playing media
+
|-
+
|  Player.Time
+
|  Elapsed time of current playing media
+
|-
+
|  Player.TimeRemaining
+
|  Remaining time of current playing media
+
|-
+
|  Player.Duration
+
|  Total duration of the current playing media
+
|-
+
|  Player.SeekTime
+
|  Time to which the user is seeking
+
|-
+
|  Player.SeekOffset
+
|  Indicates the seek offset after a seek press (eg user presses BigStepForward, player.seekoffset returns +10:00)
+
|-
+
|  Player.Volume
+
|  Current volume (between -60 and 0dB)
+
|-
+
|  Player.CacheLevel
+
|  Players current cache fill percentage (if supported by the player)
+
|-
+
|  Player.ProgressCache
+
|  Shows how much of the file is cached above current play percentage
+
|-
+
|  Player.Folderpath
+
|  Shows the full path of the currently playing song or movie
+
|-
+
|  Player.Filenameandpath
+
|  Shows the full path with filename of the currently playing song or movie
+
|- {{frodo row}}
+
|  Player.StartTime
+
|  Returns the starttime (from the epg) of a tv program, for all other videos it will return the time you started watching this video.. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Player.Title
+
|  Returns the musicplayer title for audio and the videoplayer title for videos. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|-
+
|  Playlist.Position
+
|  Position of the current item in the current playlist (video or music)
+
|-
+
|  Playlist.Length
+
|  Total size of the current playlist (video or music)
+
|-
+
|  Playlist.Random
+
|  Returns string ID's 590 (Randomize Play Enabled) or 591 (Disabled)
+
|-
+
|  Playlist.Repeat
+
|  Returns string ID's 592 (Repeat One), 593 (Repeat All), or 594 (Repeat Off)
+
|- {{frodo row}}
+
|  Pvr.NowRecordingTitle
+
|  Title of the programme being recorded '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.NowRecordingDateTime
+
|  Start date and time of the current recording'''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.NowRecordingChannel
+
|  Channel number that's being recorded '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.NextRecordingTitle
+
|  Title of the next programme that will be recorded '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.NextRecordingDateTime
+
|  Start date and time of the next recording '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.NextRecordingChannel
+
|  Channel name of the next recording '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.BackendName
+
|  Name of the backend being used '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.BackendVersion
+
|  Version of the backend that's being used '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.BackendHost
+
|  Backend hostname '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.BackendDiskSpace
+
|  Available diskspace on the backend '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.BackendChannels
+
|  Number of available channels the backend provides '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.BackendTimers
+
|  Number of timers set for the backend '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.BackendRecordings
+
|  Number of recording available on the backend '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.BackendNumber
+
|  Backend number '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.TotalDiscSpace
+
|  Total diskspace available for recordings '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.NextTimer
+
|  Next timer date '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.Duration
+
|  {{?}} '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.Time
+
|  {{?}} '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.Progress
+
|  {{?}} '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamClient
+
|  Stream client name '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamDevice
+
|  Stream device name '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamStatus
+
|  Status of the stream '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamSignal
+
|  Signal quality of the stream '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamSnr
+
|  Signal to noise ratio of the stream '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamBer
+
|  Bit error rate of the stream '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamUnc
+
|  UNC value of the stream '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamVideoBitRate
+
|  Video bitrate of the stream '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamAudioBitRate
+
|  Audio bitrate of the stream '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamDolbyBitRate
+
|  Dolby bitrate of the stream '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamProgrSignal
+
|  Signal quality of the programme '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamProgrSnr
+
|  Signal to noise ratio of the programme '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.ActStreamEncryptionName
+
|  Encryption used on the stream '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|-
+
|  Skin.CurrentTheme
+
|  Returns the current selected skin theme.
+
|-
+
|  Skin.CurrentColourTheme
+
|  Returns the current selected colour theme of the skin.
+
|-
+
|  Skin.String(name)
+
| Returns the <span class="nobr">user-set</span> skin string, set via the Skin.SetString(name) '''[[List of Built In Functions]]'''. Allows skinners to have <span class="nobr">user-customisable</span> labels.
+
|- {{frodo row}}
+
|  Skin.AspectRatio
+
|  Returns the closest aspect ratio match using the resolution info from the skin's addon.xml file. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- 
+
|  Slideshow.Altitude
+
|  Shows the altitude in meters where the current picture was taken. This is the value of the EXIF GPSInfo.GPSAltitude tag.
+
 
|-
 
|-
| Slideshow.Aperture
+
|strThumb || text || [unknown]
| Shows the F-stop used to take the current picture. This is the value of the EXIF FNumber tag (hex code 0x829D).
+
|}
 +
 
 +
==== version(music) ====
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.Author
+
|idVersion || integer || Version of the music database
| Shows the name of the person involved in writing about the current picture. This is the value of the IPTC Writer tag (hex code 0x7A).
+
 
|-
 
|-
| Slideshow.Byline
+
|idCompressCount || integer || Compression Count?
| Shows the name of the person who created the current picture. This is the value of the IPTC Byline tag (hex code 0x50).
+
|}
 +
 
 +
== The Video Library ==
 +
This database contains all information concerning TV shows, movies, and music videos. It is used in the Videos portion of XBMC.
 +
 
 +
The video database is stored in userdata/Database/MyVideos60.db.
 +
 
 +
=== Views ===
 +
Views are standard queries, often long or complicated queries saved in the database for convenience. The views below allow you to easily access all the information about each of the main media types in the Video Library, across all the linking tables.
 +
 
 +
==== episodeview ====
 +
A view that joins episode to file and tvshow (through tvshowlinkepisode) and path.
 +
 
 +
==== movieview ====
 +
A view that joins movie to file and path.
 +
 
 +
==== musicvideoview ====
 +
A view that joins musicvideo to file and path.
 +
 
 +
==== tvshowview ====
 +
View that joins tvshow to path. Also produces information about total number of episodes as well as number of watched and unwatched episodes.
 +
 
 +
=== Tables ===
 +
The information in the Video Library is organized into the following tables. Several large tables (such as [[The XBMC Database#episode|episode]], [[The XBMC Database#movie|movie]], [[The XBMC Database#settings|settings]], and [[The XBMC Database#tvshow|tvshow]]) contain the bulk of the information, while most of the others are used to link a long string to a common ID key.
 +
 
 +
==== actorlinkepisode ====
 +
This table links actors to episodes and stores role information.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.BylineTitle
+
|idActor || integer || Foreign key to [[The XBMC Database#actors|actors table]]
| Shows the title of the person who created the current picture. This is the value of the IPTC BylineTitle tag (hex code 0x55).
+
 
|-
 
|-
| Slideshow.CameraMake
+
|idEpisode || integer || Foreign key to [[The XBMC Database#episode|episode table]]
| Shows the manufacturer of the camera used to take the current picture. This is the value of the EXIF Make tag (hex code 0x010F).
+
 
|-
 
|-
| Slideshow.CameraModel
+
|strRole || text || Role the actor played in this episode
| Shows the manufacturer's model name or number of the camera used to take the current picture. This is the value of the EXIF Model tag (hex code 0x0110).
+
|}
 +
 
 +
==== actorlinkmovie ====
 +
This table links actors to movies and stores role information.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.Caption
+
|idActor || integer || Foreign key to [[The XBMC Database#actors|actors table]]
| Shows a description of the current picture. This is the value of the IPTC Caption tag (hex code 0x78).
+
 
|-
 
|-
| Slideshow.Category
+
|idMovie || integer || Foreign key to [[The XBMC Database#movie|movie table]]
| Shows the subject of the current picture as a category code. This is the value of the IPTC Category tag (hex code 0x0F).
+
 
|-
 
|-
| Slideshow.CCDWidth
+
|strRole || text || Role the actor played in this movie
| Shows the width of the CCD in the camera used to take the current picture. This is calculated from three EXIF tags (0xA002 * 0xA210 / 0xA20e).
+
|}
 +
 
 +
==== actorlinktvshow ====
 +
This table links actors to TV shows and stores role information.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.City
+
|idActor || integer || Foreign key to [[The XBMC Database#actors|actors table]]
| Shows the city where the current picture was taken. This is the value of the IPTC City tag (hex code 0x5A).
+
 
|-
 
|-
| Slideshow.Colour
+
|idShow || integer || Foreign key to [[The XBMC Database#tvshow|tvshow table]]
| Shows whether the current picture is "Colour" or "Black and White".
+
 
|-
 
|-
| Slideshow.CopyrightNotice
+
|strRole || text || Role the actor played in this TV show
| Shows the copyright notice of the current picture. This is the value of the IPTC Copyright tag (hex code 0x74).
+
|}
 +
 
 +
==== actors ====
 +
This table stores actor, artist, director, and writer information.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.Country
+
|idActor || integer || Primary Key
| Shows the full name of the country where the current picture was taken. This is the value of the IPTC CountryName tag (hex code 0x65).
+
 
|-
 
|-
| Slideshow.CountryCode
+
|strActor|| integer || Name of the actor, artist, director, or writer
| Shows the country code of the country where the current picture was taken. This is the value of the IPTC CountryCode tag (hex code 0x64).
+
 
|-
 
|-
| Slideshow.Credit
+
|strThumb || text || Thumbnail URL
| Shows who provided the current picture. This is the value of the IPTC Credit tag (hex code 0x6E).
+
|}
 +
 
 +
==== art ====
 +
This table stores URLs for video art metadata.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.DigitalZoom
+
|art_id|| integer || Primary Key
| Shows the digital zoom ratio when the current picture was taken. This is the value of the EXIF .DigitalZoomRatio tag (hex code 0xA404). 
+
 
|-
 
|-
| Slideshow.EXIFComment
+
|media_id|| integer || The id of the media this piece of art is for
| Shows a description of the current picture. This is the value of the EXIF User Comment tag (hex code 0x9286). This is the same value as Slideshow.SlideComment.
+
 
|-
 
|-
| Slideshow.EXIFDate
+
|media_type|| text || The type of media this art applies to - movie, set, tvshow, season, episode, musicvideo or actor
| Shows the localized date of the current picture. The short form of the date is used. The value of the EXIF DateTimeOriginal tag (hex code 0x9003) is preferred. If the DateTimeOriginal tag is not found, the value of DateTimeDigitized (hex code 0x9004) or of DateTime (hex code 0x0132) might be used.
+
 
|-
 
|-
| Slideshow.EXIFDescription
+
|type|| text|| The image type - poster, fanart, thumb, banner, landscape, clearlogo, clearart, characterart or discart
| Shows a short description of the current picture. The SlideComment, EXIFComment, or Caption values might contain a longer description. This is the value of the EXIF ImageDescription tag (hex code 0x010E).
+
 
|-
 
|-
| Slideshow.EXIFSoftware
+
|url|| text || Thumbnail URL
| Shows the name and version of the firmware used by the camera that took the current picture. This is the value of the EXIF Software tag (hex code 0x0131).  
+
|}
 +
 
 +
==== artistlinkmusicvideo ====
 +
This table links artists to music videos.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.EXIFTime
+
|idArtist || integer || Foreign key to [[The XBMC Database#actors|actors table]]
| Shows the date/timestamp of the current picture. The localized short form of the date and time is used. The value of the EXIF DateTimeOriginal tag (hex code 0x9003) is preferred. If the DateTimeOriginal tag is not found, the value of DateTimeDigitized (hex code 0x9004) or of DateTime (hex code 0x0132) might be used.
+
 
|-
 
|-
| Slideshow.Exposure
+
|idMVideo || integer || Foreign key to [[The XBMC Database#musicvideo|musicvideo table]]
| Shows the class of the program used by the camera to set exposure when the current picture was taken. Values include "Manual", "Program (Auto)", "Aperture priority (Semi-Auto)", "Shutter priority (semi-auto)", etc. This is the value of the EXIF ExposureProgram tag (hex code 0x8822).
+
|}
 +
 
 +
==== bookmark ====
 +
This table stores bookmarks, which are timestamps representing the point in a video where a user stopped playback, an explicit bookmark requested by the user, or an automatically generated episode bookmark.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.ExposureBias
+
|idBookmark || integer || Primary Key
| Shows the exposure bias of the current picture. Typically this is a number between -99.99 and 99.99. This is the value of the EXIF ExposureBiasValue tag (hex code 0x9204).
+
 
|-
 
|-
| Slideshow.ExposureMode
+
|idFile || integer || Foreign key to [[The XBMC Database#files|files table]]
| Shows the exposure mode of the current picture. The possible values are "Automatic", "Manual", and "Auto bracketing". This is the value of the EXIF ExposureMode tag (hex code 0xA402).
+
 
|-
 
|-
| Slideshow.ExposureTime
+
|timeInSeconds || double || Time in seconds of bookmark location
| Shows the exposure time of the current picture, in seconds. This is the value of the EXIF ExposureTime tag (hex code 0x829A). If the ExposureTime tag is not found, the ShutterSpeedValue tag (hex code 0x9201) might be used.
+
 
|-
 
|-
| Slideshow.Filedate
+
|totalTimeInSeconds || integer || Time in seconds of the video
| Shows the file date of the current picture
+
|-
+
| Slideshow.Filename
+
| Shows the file name of the current picture
+
 
|-
 
|-
| Slideshow.Filesize
+
|thumbNailImage || text || Thumbnail for bookmark
| Shows the file size of the current picture
+
 
|-
 
|-
| Slideshow.FlashUsed
+
|player || text || Player used to store bookmark
| Shows the status of flash when the current picture was taken. The value will be either "Yes" or "No", and might include additional information. This is the value of the EXIF Flash tag (hex code 0x9209). 
+
 
|-
 
|-
| Slideshow.FocalLength
+
|playerState || text || Player's internal state in XML
| Shows the focal length of the lens, in mm. This is the value of the EXIF FocalLength tag (hex code 0x920A).
+
 
|-
 
|-
| Slideshow.FocusDistance
+
|type || integer || Type of bookmark (0=standard, 1=resume, 2=episode
| Shows the distance to the subject, in meters. This is the value of the EXIF SubjectDistance tag (hex code 0x9206).
+
 
 +
|}
 +
 
 +
==== directorlinkepisode ====
 +
This table links directors to TV show episodes.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.Headline
+
|idDirector || integer || Foreign key to [[The XBMC Database#actors|actors table]]
| Shows a synopsis of the contents of the current picture. This is the value of the IPTC Headline tag (hex code 0x69).
+
|-
+
| Slideshow.ImageType
+
| {{Gotham note |Shows the color components of the current picture. This is the value of the IPTC ImageType tag (hex code 0x82).}}
+
 
|-
 
|-
| Slideshow.IPTCDate
+
|idEpisode || integer || Foreign key to [[The XBMC Database#episode|episode table]]
| Shows the date when the intellectual content of the current picture was created, rather than when the picture was created. This is the value of the IPTC DateCreated tag (hex code 0x37).
+
 
|-
 
|-
| Slideshow.ISOEquivalence
+
|strRole || text || [Appears to be unused]
| Shows the ISO speed of the camera when the current picture was taken. This is the value of the EXIF ISOSpeedRatings tag (hex code 0x8827).
+
|}
 +
 
 +
==== directorlinkmovie ====
 +
This table links directors to movies.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.Keywords
+
|idDirector || integer || Foreign key to [[The XBMC Database#actors|actors table]]
| Shows keywords assigned to the current picture. This is the value of the IPTC Keywords tag (hex code 0x19).
+
 
|-
 
|-
| Slideshow.Latitude
+
|idMovie || integer || Foreign key to [[The XBMC Database#movie|movie table]]
| Shows the latitude where the current picture was taken (degrees, minutes, seconds North or South). This is the value of the EXIF GPSInfo.GPSLatitude and GPSInfo.GPSLatitudeRef tags.
+
|}
 +
 
 +
==== directorlinkmusicvideo ====
 +
This table links directors to music videos.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.LightSource
+
|idDirector || integer || Foreign key to [[The XBMC Database#actors|actors table]]
| Shows the kind of light source when the picture was taken. Possible values include "Daylight", "Fluorescent", "Incandescent", etc. This is the value of the EXIF LightSource tag (hex code 0x9208).
+
 
|-
 
|-
| Slideshow.LongEXIFDate
+
|idMVideo || integer || Foreign key to [[The XBMC Database#musicvideo|musicvideo table]]
| {{Gotham note|Shows only the localized date of the current picture. The long form of the date is used. The value of the EXIF DateTimeOriginal tag (hex code 0x9003) is preferred. If the DateTimeOriginal tag is not found, the value of DateTimeDigitized (hex code 0x9004) or of DateTime (hex code 0x0132) might be used.}}
+
|}
 +
 
 +
==== directorlinktvshow ====
 +
This table links directors to TV shows.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.LongEXIFTime
+
|idDirector || integer || Foreign key to [[The XBMC Database#actors|actors table]]
| {{Gotham note|Shows the date/timestamp of the current picture. The localized long form of the date and time is used. The value of the EXIF DateTimeOriginal tag (hex code 0x9003) is preferred. if the DateTimeOriginal tag is not found, the value of DateTimeDigitized (hex code 0x9004) or of DateTime (hex code 0x0132) might be used.}}
+
 
|-
 
|-
| Slideshow.Longitude
+
|idShow || integer || Foreign key to [[The XBMC Database#tvshow|tvshow table]]
| Shows the longitude where the current picture was taken (degrees, minutes, seconds East or West). This is the value of the EXIF GPSInfo.GPSLongitude and GPSInfo.GPSLongitudeRef tags.
+
|}
 +
 
 +
==== episode ====
 +
This table stores television episode information. Information concerning the series is stored in [[The XBMC Database#tvshow|tvshow]]. To link an episode to its parent series, use [[The XBMC Database#tvshowlinkepisode|tvshowlinkepisode]].
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 
|-
 
|-
| Slideshow.MeteringMode
+
|idEpisode || integer || Primary Key
| Shows the metering mode used when the current picture was taken. The possible values are "Center weight", "Spot", or "Matrix". This is the value of the EXIF MeteringMode tag (hex code 0x9207).
+
 
|-
 
|-
| Slideshow.ObjectName
+
|c00 || text |Episode Title
Shows a shorthand reference for the current picture. This is the value of the IPTC ObjectName tag (hex code 0x05).
+
 
|-
 
|-
| Slideshow.Orientation
+
|c01 || text |Plot Summary
Shows the orientation of the current picture. Possible values are "Top Left", "Top Right", "Left Top", "Right Bottom", etc. This is the value of the EXIF Orientation tag (hex code 0x0112).
+
 
|-
 
|-
| Slideshow.Path
+
|c02 || text |[unknown - listed as Votes]
Shows the file path of the current picture
+
 
|-
 
|-
| Slideshow.Process
+
|c03 || text |Rating
Shows the process used to compress the current picture
+
 
|-
 
|-
| Slideshow.ReferenceService
+
|c04 || text |Writer
Shows the Service Identifier of a prior envelope to which the current picture refers. This is the value of the IPTC ReferenceService tag (hex code 0x2D).
+
 
|-
 
|-
| Slideshow.Resolution
+
|c05 || text |First Aired
Shows the dimensions of the current picture (Width x Height)
+
 
|-
 
|-
| Slideshow.SlideComment
+
|c06 || text |Thumbnail URL
Shows a description of the current picture. This is the value of the EXIF User Comment tag (hex code 0x9286). This is the same value as Slideshow.EXIFComment.
+
 
|-
 
|-
| Slideshow.SlideIndex
+
|c07 || text |[unknown - listed as Thumbnail URL Spoof, unused?]
Shows the slide index of the current picture
+
 
|-
 
|-
| Slideshow.Source
+
|c08 || text |Has the episode been watched? (unused?)
Shows the original owner of the current picture. This is the value of the IPTC Source tag (hex code 0x73).
+
 
|-
 
|-
| Slideshow.SpecialInstructions
+
|c09 || text |Episode length in minutes
Shows other editorial instructions concerning the use of the current picture. This is the value of the IPTC SpecialInstructions tag (hex code 0x28).
+
 
|-
 
|-
| Slideshow.State
+
|c10 || text ||  Director
| Shows the State/Province where the current picture was taken. This is the value of the IPTC ProvinceState tag (hex code 0x5F).
+
|-
+
| Slideshow.Sublocation
+
{{Gotham note |Shows the location within a city where the current picture was taken - might indicate the nearest landmark. This is the value of the IPTC SubLocation tag (hex code 0x5C).}}
+
 
|-
 
|-
| Slideshow.SupplementalCategories
+
|c11 || text ||  [unknown - listed as Indentifier]
| Shows supplemental category codes to further refine the subject of the current picture. This is the value of the IPTC SuppCategory tag (hex code 0x14).
+
|-
+
| Slideshow.TimeCreated
+
{{Gotham note|Shows the time when the intellectual content of the current picture was created, rather than when the picture was created. This is the value of the IPTC TimeCreated tag (hex code 0x3C).}}
+
 
|-
 
|-
| Slideshow.TransmissionReference
+
|c12 || text |Season Number
Shows a code representing the location of original transmission of the current picture. This is the value of the IPTC TransmissionReference tag (hex code 0x67).
+
 
|-
 
|-
| Slideshow.Urgency
+
|c13 || text ||  Episode Number
| {{Gotham note|Shows the urgency of the current picture. Values are 1-9. The 1 is most urgent. Some image management programs use urgency to indicate picture rating, where urgency 1 is 5 stars and urgency 5 is 1 star. Urgencies 6-9 are not used for rating. This is the value of the IPTC Urgency tag (hex code 0x0A).}}
+
 
|-
 
|-
| Slideshow.WhiteBalance
+
|c14 || text |[unknown - listed as Original Title, unused?]
Shows the white balance mode set when the current picture was taken. The possible values are "Manual" and "Auto". This is the value of the EXIF WhiteBalance tag (hex code 0xA403).
+
 
|-
 
|-
| System.AddonTitle(id)
+
|c15 || text ||  Season formatted for sorting
| Returns the title of the specified addon. Instead of specifying the id directly, one can also use an infolabel (eg. $INFO[Skin.String(Foo)])
+
|-
|-
+
|c16 || text ||  Episode formatted for sorting
| System.Time
+
|-
Current time
+
|c17 || text ||  Bookmark
|-  
+
|-
| System.Time(format)
+
|c18 || text ||  Not used
| Shows hours (hh), minutes (mm) or seconds (ss). When 12 hour clock is used (xx) will return AM/PM. Also supported: (hh:mm), (mm:ss), (hh:mm:ss), (hh:mm:ss). (xx) option added after dharma
+
|-
|-
+
|c19 || text ||  Not used
| System.Date
+
|-
Current date
+
|c20 || text ||  Not used
|-  
+
|-
| System.Date(format)
+
|idFile || integer ||  Foreign key to the [[The XBMC Database#files|files table]]
| Show current date using format, available markings: d (day of month 1-31), dd (day of month 01-31), ddd (short day of the week Mon-Sun), DDD (long day of the week Monday-Sunday), m (month 1-12), mm (month 01-12), mmm (short month name Jan-Dec), MMM (long month name January-December), yy (2-digit year), yyyy (4-digit year). Added after dharma.
+
|}
|-
+
| System.AlarmPos
+
Shutdown Timer position
+
|-  
+
| System.BatteryLevel
+
| Returns the remaining battery level in range 0-100
+
|-
+
| System.FreeSpace
+
Total Freespace on the drive
+
|-  
+
| System.UsedSpace
+
| Total Usedspace on the drive
+
|-
+
| System.TotalSpace
+
Totalspace on the drive
+
|-  
+
| System.UsedSpacePercent
+
| Total Usedspace Percent on the drive
+
|-
+
| System.FreeSpacePercent
+
Total Freespace Percent on the drive
+
|-  
+
| System.CPUTemperature
+
| Current CPU temperature
+
|-
+
| System.GPUTemperature
+
Current GPU temperature
+
|-
+
|  System.FanSpeed
+
|  Current fan speed
+
|-
+
|  System.BuildVersion
+
|  Version of build
+
|-
+
|  System.BuildDate
+
|  Date of build
+
|-
+
|  System.FriendlyName
+
|  Returns the xbmc instance name. It will auto append (%hostname%) in case the device name was not changed. eg. "XBMC (htpc)"
+
|-
+
|  System.FPS
+
|  Current rendering speed (frames per second)
+
|-
+
|  System.FreeMemory
+
|  Amount of free memory in Mb
+
|-
+
|  System.ScreenMode
+
|  Screenmode (eg windowed / fullscreen)
+
|-
+
|  System.ScreenWidth
+
|  Width of screen in pixels
+
|-
+
|  System.ScreenHeight
+
|  Height of screen in pixels
+
|-
+
|  System.StartupWindow
+
|  The Window XBMC will load on startup '''([[:Category:Gotham feature|Future Gotham addition]])'''
+
|-
+
|  System.CurrentWindow
+
|  Current Window we are in
+
|-
+
|  System.CurrentControl
+
|  Current focused control
+
|-
+
|  System.DVDLabel
+
|  Label of the disk in the <span class="nobr">DVD-ROM</span> drive
+
|-
+
|  System.HddTemperature
+
|  Hdd temperature
+
|-
+
|  System.KernelVersion
+
|  System kernel version
+
|-
+
|  System.Uptime
+
|  System current uptime
+
|-
+
|  System.TotalUptime
+
|  System total uptime
+
|-
+
|  System.CpuFrequency
+
|  System cpu frequency
+
|-
+
|  System.ScreenResolution
+
|  Screen resolution
+
|-
+
|  System.VideoEncoderInfo
+
|  Video encoder info
+
|-
+
|  System.InternetState
+
|  Will return the internet state, connected or not connected
+
and for Conditional use: Connected->TRUE, not Connected->FALSE, do not use to check status in a pythonscript since it is threaded.
+
|-
+
|  System.Language
+
|  Shows the current language
+
|-
+
|  System.GetBool(boolean)
+
|  Returns the value of any standard system boolean setting.  Will not work with settings in advancedsettings.xml
+
|-
+
|  System.ProfileName
+
|  Shows the User name of the currently logged in XBMC user
+
|-
+
|  System.ProfileCount
+
|  Shows the number of defined profiles
+
|-
+
|  System.ProfileAutoLogin
+
The profile XBMC will auto login to '''([[:Category:Gotham feature|Future Gotham addition]])'''
+
|-
+
|  System.TemperatureUnits
+
|  Shows Celsius or Fahrenheit symbol
+
|-
+
|  Visualisation.Preset
+
|  Shows the current preset of the visualisation
+
|-
+
|  Visualisation.Name
+
|  Shows the name of the visualisation
+
|-
+
|  VideoPlayer.Time
+
|  Current time in movie
+
|-
+
|  VideoPlayer.TimeRemaining
+
|  Current remaining time in movie
+
|-
+
|  VideoPlayer.TimeSpeed
+
|  Current time + playspeed. eg 1:23:14 (-4x)
+
|-
+
|  VideoPlayer.Duration
+
|  Length of current movie
+
|-
+
|  VideoPlayer.Title
+
|  Title of currently playing video. If it's in the database it will return the database title, else the filename
+
|-
+
|  VideoPlayer.TVShowTitle
+
|  Title of currently playing episode's tvshow name
+
|-
+
|  VideoPlayer.Season
+
|  Season number of the currently playing episode
+
|-
+
|  VideoPlayer.Episode
+
|  Episode number of the currently playing episode
+
|-
+
|  VideoPlayer.Genre
+
|  Genre(s) of current movie, if it's in the database
+
|-
+
|  VideoPlayer.Director
+
|  Director of current movie, if it's in the database
+
|-
+
|  VideoPlayer.Country
+
|  Production country of current movie, if it's in the database
+
|-
+
|  VideoPlayer.Year
+
|  Year of release of current movie, if it's in the database
+
|-
+
|  VideoPlayer.Rating
+
|  IMDb user rating of current movie, if it's in the database
+
|-
+
|  VideoPlayer.Votes
+
|  IMDb votes of current movie, if it's in the database '''([[:Category:Gotham feature|Future Gotham addition]])'''
+
|-
+
|  VideoPlayer.RatingAndVotes
+
|  IMDb user rating and votes of current movie, if it's in the database
+
|-
+
|  VideoPlayer.mpaa
+
|  MPAA rating of current movie, if it's in the database
+
|-
+
|  VideoPlayer.PlaylistPosition
+
|  Position of the current song in the current video playlist
+
|-
+
|  VideoPlayer.PlaylistLength
+
|  Total size of the current video playlist
+
|-
+
|  VideoPlayer.Cast
+
|  A concatenated string of cast members of the current movie, if it's in the database
+
|-
+
|  VideoPlayer.CastAndRole
+
|  A concatenated string of cast members and roles of the current movie, if it's in the database
+
|-
+
|  VideoPlayer.Album
+
|  Album from which the current Music Video is from, if it's in the database
+
|-
+
|  VideoPlayer.Artist
+
|  Artist(s) of current Music Video, if it's in the database
+
|-
+
|  VideoPlayer.Studio
+
|  Studio of current Music Video, if it's in the database
+
|-
+
|  VideoPlayer.Writer
+
|  Name of Writer of current playing Video, if it's in the database
+
|-
+
|  VideoPlayer.Tagline
+
|  Small Summary of current playing Video, if it's in the database
+
|-
+
|  VideoPlayer.PlotOutline
+
|  Small Summary of current playing Video, if it's in the database
+
|-
+
|  VideoPlayer.Plot
+
|  Complete Text Summary of current playing Video, if it's in the database
+
|-
+
|  VideoPlayer.LastPlayed
+
|  Last play date of current playing Video, if it's in the database
+
|- class="userrow
+
|  VideoPlayer.PlayCount
+
|  Playcount of current playing Video, if it's in the database
+
|- class="userrow
+
|  VideoPlayer.VideoCodec
+
|  Shows the video codec of the currently playing video (common values: see ListItem.VideoCodec)
+
|-
+
|  VideoPlayer.VideoResolution
+
|  Shows the video resolution of the currently playing video (possible values: see ListItem.VideoResolution)
+
|-
+
|  VideoPlayer.VideoAspect
+
|  Shows the aspect ratio of the currently playing video (possible values: see ListItem.VideoAspect)
+
|-
+
|  VideoPlayer.AudioCodec
+
|  Shows the audio codec of the currently playing video (common values: see ListItem.AudioCodec)
+
|-
+
|  VideoPlayer.AudioChannels
+
|  Shows the number of audio channels of the currently playing video (possible values: see ListItem.AudioChannels)
+
|- {{frodo row}}
+
|  VideoPlayer.EndTime
+
|  End date of the currently playing programme (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.NextTitle
+
|  Title of the programme that will be played next (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.NextGenre
+
|  Genre of the programme that will be played next (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.NextPlot
+
|  Plot of the programme that will be played next (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.NextPlotOutline
+
|  Plot outline of the programme that will be played next (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.NextStartTime
+
|  Start time of the programme that will be played next (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.NextEndTime
+
|  End time of the programme that will be played next (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.NextDuration
+
|  Duration of the programme that will be played next (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.ChannelName
+
|  Name of the curently tuned channel (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.ChannelNumber
+
|  Number of the curently tuned channel (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.ChannelGroup
+
|  Group of the curently tuned channel (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  VideoPlayer.ParentalRating
+
|  Parental rating of the currently playing programme (PVR). '''([[:Category:Frodo feature|Frodo addition]])'''
+
|-
+
|  Weather.Conditions
+
|  Current weather conditions – this is looked up in a background process.
+
|-
+
|  Weather.Temperature
+
|  Current weather temperature
+
|-
+
|  Weather.Location
+
|  City/town which the above two items are for
+
|-
+
|  Window([window]).Property(key)
+
|  Window property. (key can be any value, optional window can be id or name)
+
|-
+
|  Window.Property(xmlfile)
+
|  Displays the name of the xml file currently shown
+
|-
+
|  Window(Home).Property(key)
+
|  The home window has the following info labels.
+
Movies.Count, Movies.Watched, Movies.UnWatched, TVShows.Count, TVShows.Watched, TVShows.UnWatched, Episodes.Count, Episodes.Watched, Episodes.UnWatched, MusicVideos.Count, MusicVideos.Watched, MusicVideos.UnWatched, Music.SongsCount, Music.AlbumsCount, Music.ArtistsCount
+
  
LatestMovie.[1-10].Title, LatestMovie.[1-10].Year, LatestMovie.[1-10].RunningTime, LatestMovie.[1-10].Rating, LatestMovie.[1-10].Plot, LatestMovie.[1-10].Trailer, LatestMovie.[1-10].Thumb, LatestMovie.[1-10].Fanart, LatestMovie.[1-10].Path
+
==== files ====
 +
This table stores filenames and links the path.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idFile || integer || Primary Key
 +
|-
 +
|idPath || integer || Foreign key to [[The XBMC Database#path|path table]]
 +
|-
 +
|strFilename || text || Full name of file including extension
 +
|-
 +
|playCount || integer ||
 +
|-
 +
|lastPlayed || text ||
 +
|}
  
LatestEpisode.[1-10].ShowTitle, LatestEpisode.[1-10].EpisodeTitle, LatestEpisode.[1-10].EpisodeNo, LatestEpisode.[1-10].EpisodeSeason, LatestEpisode.[1-10].EpisodeNumber, LatestEpisode.[1-10].Rating, LatestEpisode.[1-10].Plot, LatestEpisode.[1-10].Thumb, LatestEpisode.[1-10].ShowThumb, LatestEpisode.[1-10].SeasonThumb, LatestEpisode.[1-10].Fanart, LatestEpisode.[1-10].Path
+
==== genre ====
 +
This table stores genre information. For convenience the contents are duplicated in [[The XBMC Database#movie|movie]] and [[The XBMC Database#tvshow|tvshow]], so a join isn't necessary.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idGenre || integer || Primary Key
 +
|-
 +
|strGenre || text || Genre label
 +
|}
  
LatestMusicVideo.[1-10].Title, LatestMusicVideo.[1-10].Thumb, LatestMusicVideo.[1-10].Year, LatestMusicVideo.[1-10].Plot, LatestMusicVideo.[1-10].RunningTime, LatestMusicVideo.[1-10].Path, LatestMusicVideo.[1-10].Artist, LatestMusicVideo.[1-10].Fanart
+
==== genrelinkmovie ====
 +
This table links genres to movies. (The contents are also stored in movies.c14, though.)
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idGenre || integer || Foreign key to [[The XBMC Database#genre|genre table]]
 +
|-
 +
|idMovie || integer || Foreign key to [[The XBMC Database#movie|movie table]]
 +
|}
  
LatestSong.[1-10].Title, LatestSong.[1-10].Artist, LatestSong.[1-10].Album, LatestSong.[1-10].Year, LatestSong.[1-10].Rating, LatestSong.[1-10].Thumb, LatestSong.[1-10].Fanart, LatestSong.[1-10].Path
+
==== genrelinkmusicvideo ====
 +
This table links genres to music videos.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idGenre || integer || Foreign key to [[The XBMC Database#genre|genre table]]
 +
|-
 +
|idMVideo || integer || Foreign key to [[The XBMC Database#musicvideo|musicvideo table]]
 +
|}
  
LatestAlbum.[1-10].Title, LatestAlbum.[1-10].Artist, LatestAlbum.[1-10].Year, LatestAlbum.[1-10].Rating, LatestAlbum.[1-10].Thumb, LatestAlbum.[1-10].Fanart, LatestAlbum.[1-10].Path
+
==== genrelinktvshow ====
|-  
+
This table links genres to TV show. (The contents are also stored in tvshow.c08, though.)
| Window(Weather).Property(key)
+
{|class="wikitable"
|  The weather window has the following info labels.
+
! Column Name || Data Type || Description
Location, Updated, Current.Condition, Current.Temperature, Current.FeelsLike, Current.UVIndex, Current.Wind (From <wind dir.> at <speed> <unit>), Current.WindSpeed, Current.WindDirection, Current.DewPoint, Current.Humidity, Day[0-6].Title, Day[0-6].HighTemp, Day[0-6].LowTemp, Day[0-6].Outlook
+
|-
 +
|idGenre || integer || Foreign key to [[The XBMC Database#genre|genre table]]
 +
|-
 +
|idShow || integer || Foreign key to [[The XBMC Database#tvshow|tvshow table]]
 
|}
 
|}
  
=== Images Available in XBMC ===
+
==== movie ====
{| class="wikitable"
+
This table stores movie information.
! style="background: lightgrey; width: 150px" | '''infolabels'''
+
{|class="wikitable"
! style="background: lightgrey; width: 1500px" | '''Definition'''
+
! Column Name || Data Type || Description
|-
+
|  Container.FolderThumb
+
|  Thumbnail Image of the current displayed folder of list and thumb panels
+
|-
+
|  Container.TvshowThumb
+
|  Thumbnail Image of the parent TV show
+
|-
+
|  Container.SeasonThumb
+
|  Thumbnail Image of the parent TV show season
+
|-
+
|  Fanart.Image
+
|  Fanart image for the parent TV Show
+
|-
+
|  ListItem.Thumb
+
|  Shows the thumbnail (if it exists) of the currently selected item in a list or thumb control
+
|-
+
|  ListItem.Icon
+
|  Shows the thumbnail (if it exists) of the currently selected item in a list or thumb control. If no thumbnail image exists, it will show the icon.
+
|-
+
|  ListItem.ActualIcon
+
|  Shows the icon of the currently selected item in a list or thumb control.
+
|- {{frodo row}}
+
| ListItem.Art(thumb)
+
|  Returns the thumbnail of the currently selected item. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.Art(poster)
+
|  Returns the poster of the currently selected tv show. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.Art(banner)
+
|  Returns the banner of the currently selected tv show. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.Art(fanart)
+
|  Returns the fanart image of the currently selected item. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.Art(tvshow.poster)
+
|  Returns the tv show poster of the parent container. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.Art(tvshow.banner)
+
|  Returns the tv show banner of the parent container. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  ListItem.Art(season.poster)
+
|  Returns the season poster of the currently selected season. '''([[:Category:Frodo feature|Frodo addition]]) Only available in DialogVideoInfo.xml'''
+
|- {{frodo row}}
+
|  ListItem.Art(season.banner)
+
|  Returns the season banner of the currently selected season. '''([[:Category:Frodo feature|Frodo addition]]) Only available in DialogVideoInfo.xml'''
+
|- {{frodo row}}
+
|  ListItem.Art(season.fanart)
+
|  Returns the fanart image of the currently selected season. '''([[:Category:Frodo feature|Frodo addition]]) Only available in DialogVideoInfo.xml'''
+
|-
+
|  ListItem.Overlay
+
|  Shows the Overlay Icon status (compressed file [OverlayRAR.png], Trainer [OverlayTrainer.png], watched [OverlayWatched.png], unwatched [OverlayUnwatched.png], locked [OverlayLocked.png]) of the currently selected item in a list or thumb control.
+
|-
+
|  ListItem.StarRating
+
|  Returns a value of 0 to 5 as a graphical display from images named rating0.png to rating5.png of the skin
+
|-
+
|  ListItem.Property(ArtistThumb)
+
|  Thumbnail Image of the parent artist, for use in dialogalbuminfo.xml and dialogsonginfo.xml
+
|-
+
|  ListItem.Property(Addon.StarRating)
+
|  Returns a value of rating0.png to rating5.png for the currently selected addon
+
|- {{frodo row}}
+
|  ListItem.Property(Fanart_Image)
+
|  Fanart Image currently selected item or of the parent TV show '''([[:Category:Frodo feature|Frodo addition]])'''
+
|-
+
|  ListItem.Property(SeasonThumb)
+
|  Thumbnail Image of the parent TV show season, for use in dialogvideoinfo.xml
+
|- {{Frodo row}}
+
|  ListItem.Property(TVShowThumb)
+
|  Thumbnail Image of the parent TV show, for use in dialogvideoinfo.xml  '''([[:Category:Frodo feature|Frodo addition]] available anywhere)'''
+
|-
+
|  MusicPlayer.Cover
+
|  Cover of currently playing album
+
|-
+
|  MusicPlayer.Property(Fanart_Image)
+
|  Fanart image of the currently playing artist
+
|- {{frodo row}}
+
|  Player.Art(fanart)
+
|  Fanart Image the currently playing episode's parent TV show  '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Player.Art(tvshowthumb)
+
|  Thumbnail Image the currently playing episode's parent TV show  '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Player.Art(poster)
+
|  Poster Image the currently playing item.  '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Player.Art(thumb)
+
|  Thumbnail Image the currently playing item.  '''([[:Category:Frodo feature|Frodo addition]])'''
+
|-
+
|  Player.StarRating
+
|  Returns a value of 0 to 5 as a graphical display from images named rating0.png to rating5.png of the skin
+
|- {{frodo row}}
+
|  Pvr.NowRecordingChannelIcon
+
|  Channel icon of the programme currently being recorded. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|- {{frodo row}}
+
|  Pvr.NextRecordingChannelIcon
+
|  Channel icon of the programme that will be recorded next. '''([[:Category:Frodo feature|Frodo addition]])'''
+
|-
+
|  Skin.String(name)
+
| Returns the image or image folder set by the user via a Skin.SetPath(name) or Skin.SetImage(name) '''[[List of Built In Functions]]'''. Allows skinners to have <span class="nobr">user-customisable</span> images and multiimages.
+
|-
+
| System.AddonIcon(id)
+
| Returns the Icon of the specified addon. Instead of specifying the id directly, one can also use an infolabel (eg. $INFO[Skin.String(Foo)])
+
 
|-
 
|-
System.ProfileThumb
+
|idMovie || integer || Primary Key
Shows the Thumbnail image of the currently logged in XBMC user
+
|-
|-  
+
|c00 || text |Local Movie Title
VideoPlayer.Cover
+
|-
Cover of currently playing movie
+
|c01 || text || Movie Plot
|-  
+
|-
Weather.Conditions
+
|c02 || text |Movie Plot Outline
Image of current weather conditions (NOTE: Can be used to load/refresh weather conditions)
+
|-
|-  
+
|c03 || text |Movie Tagline
Window([window]).Property(key)
+
|-
Window property. (key can be any value, optional window can be id or name)
+
|c04 || text |Rating Votes
|-  
+
|-
Window(Weather).Property(key)
+
|c05 || text |Rating
The weather window has the following info images.
+
|-
Current.ConditionIcon, Day[0-6].OutlookIcon, Current.FanartCode, Day[0-6].FanartCode
+
|c06 || text |Writers
 +
|-
 +
|c07 || text ||  Year Released
 +
|-
 +
|c08 || text ||  Thumbnails
 +
|-
 +
|c09 || text ||  IMDB ID
 +
|-
 +
|c10 || text ||  Title formatted for sorting
 +
|-
 +
|c11 || text ||  Runtime (UPnP devices see this as seconds)
 +
|-
 +
|c12 || text ||  MPAA Rating
 +
|-
 +
|c13 || text ||  [http://www.imdb.com/chart/top IMDB Top 250] Ranking
 +
|-
 +
|c14 || text |Genre
 +
|-
 +
|c15 || text |Director
 +
|-
 +
|c16 || text |Original Movie Title
 +
|-
 +
|c17 || text ||  [unknown - listed as Thumbnail URL Spoof]
 +
|-
 +
|c18 || text ||  Studio
 +
|-
 +
|c19 || text ||  Trailer URL
 +
|-
 +
|c20 || text ||  Fanart URLs
 +
|-
 +
|c21 || text ||  Country (Added in r29886[http://trac.xbmc.org/changeset/29886/trunk])
 +
|-
 +
|c23 || text ||  idPath
 +
|-
 +
|idFile || integer ||  Foreign Key to [[The XBMC Database#files|files table]]
 
|}
 
|}
  
== See also ==
+
==== movielinktvshow ====
'''Development:'''
+
This table links movies to TV shows.
* [[Add-on development]]
+
{|class="wikitable"
* [[Skinning]]
+
! Column Name || Data Type || Description
 +
|-
 +
|idMovie || integer || Foreign key to [[The XBMC Database#movie|movie table]]
 +
|-
 +
|idShow || integer || Foreign key to [[The XBMC Database#tvshow|tvshow table]]
 +
|}
 +
 
 +
==== musicvideo ====
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idMVideo || integer || Primary Key
 +
|-
 +
|c00 || text || Title
 +
|-
 +
|c01 || text || Thumbnail URL
 +
|-
 +
|c02 || text || [unknown - listed as Thumbnail URL spoof]
 +
|-
 +
|c03 || text || Play count (unused?)
 +
|-
 +
|c04 || text || Run time
 +
|-
 +
|c05 || text || Director
 +
|-
 +
|c06 || text || Studios
 +
|-
 +
|c07 || text || Year
 +
|-
 +
|c08 || text || Plot
 +
|-
 +
|c09 || text || Album
 +
|-
 +
|c10 || text || Artist
 +
|-
 +
|c11 || text || Genre
 +
|-
 +
|c12 || text || Track
 +
|-
 +
|idFile || integer ||  Foreign Key to [[The XBMC Database#files|files table]]
 +
|}
 +
 
 +
==== path ====
 +
This table stores path information.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idPath || integer || Primary Key
 +
|-
 +
|strPath || text || Path URL
 +
|-
 +
|strContent || text || Type of content (tvshows, movies, etc...)
 +
|-
 +
|strScraper || text || XML file of scraper used for this path
 +
|-
 +
|strHash || text || Hash
 +
|-
 +
|scanRecursive || integer || Recursive scan setting
 +
|-
 +
|useFolderNames || bool || User folder names setting
 +
|-
 +
|strSettings || text || Custom settings used by scraper
 +
|}
 +
 
 +
==== seasons ====
 +
This table stores the links between tv show and seasons.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idSeason || integer || Primary Key
 +
|-
 +
|idShow|| integer || Foreign key to [[The XBMC Database#tvshow|tvshow table]]
 +
|-
 +
|season || integer || Season number
 +
|}
 +
 
 +
==== sets ====
 +
This table stores the id and name for movie sets. Sets are linked to movies in the movie table (idSet column).
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idSet || integer || Primary Key
 +
|-
 +
|strSet || text || The name of the set
 +
|}
 +
 
 +
==== settings ====
 +
This table stores settings for individual files.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idFile || integer || Foreign Key to [[The XBMC Database#files|files table]]
 +
|-
 +
|Interleaved || bool || Interleaved
 +
|-
 +
|Nocache || bool || NoCache
 +
|-
 +
|Deinterlace || bool || Deinterlace
 +
|-
 +
|FilmGrain|| integer || FilmGrain
 +
|-
 +
|ViewMode|| integer || ViewMode
 +
|-
 +
|ZoomAmount|| float || ZoomAmount
 +
|-
 +
|PixelRatio|| float || PixelRatio
 +
|-
 +
|AudioStream || integer || Selected audio stream
 +
|-
 +
|SubtitleStream || integer || Selected subtitle stream
 +
|-
 +
|SubtitleDelay || float || Amount of delay for subtitles
 +
|-
 +
|SubtitleOn || bool || Enable subtitles
 +
|-
 +
|Brightness || integer || Brightness
 +
|-
 +
|Contrast || integer || Contrast
 +
|-
 +
|Gamma || integer || Gamma
 +
|-
 +
|VolumeAmplification || float || VolumeAmplification
 +
|-
 +
|AudioDelay || float || AudioDelay
 +
|-
 +
|OutputToAllSpeakers || bool || OutputToAllSpeakers
 +
|-
 +
|ResumeTime || integer || ResumeTime
 +
|-
 +
|Crop || bool || Crop
 +
|-
 +
|CropLeft || integer || CropLeft
 +
|-
 +
|CropRight || integer || CropRight
 +
|-
 +
|CropTop || integer || CropTop
 +
|-
 +
|CropBottom || integer || CropBottom
 +
|}
 +
 
 +
==== stacktimes ====
 +
This table stores playing times for files (used for playing multi-file videos).
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idFile || integer || Foreign key to [[The XBMC Database#files|files table]]
 +
|-
 +
|times|| text || Times
 +
|}
 +
 
 +
==== streamdetails ====
 +
This table contains information regarding codecs used, aspect ratios etc
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idFile || integer || Foreign Key to [[The XBMC Database#files|files table]]
 +
|-
 +
|iStreamType || integer || 0 = video, 1 = audio, 2 = subtitles
 +
|-
 +
|strVideoCodec|| text || Video codex (xvid etc)
 +
|-
 +
|fVideoAspect|| real || Aspect ratio
 +
|-
 +
|iVideoWidth|| integer || Width of the video
 +
|-
 +
|iVideoHeight|| integer || Height of the video
 +
|-
 +
|strAudioCodec|| text || Audio codec (aac, mp3 etc)
 +
|-
 +
|iAudioChannels|| integer || Number of audio channels (2 for stereo, 6 for 5.1 etc)
 +
|-
 +
|strAudioLanguage|| text || Language of the audio track
 +
|-
 +
|strSubtitleLanguage|| text || Language of the subtitles
 +
|}
 +
 
 +
==== studio ====
 +
This table stores studio information.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idStudio || integer || Primary Key
 +
|-
 +
|strStudio || text || Studio Label
 +
|}
 +
 
 +
==== studiolinkmovie ====
 +
This table links studios to movies.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idStudio || integer || Foreign key to [[The XBMC Database#studio|studio table]]
 +
|-
 +
|idMovie || integer || Foreign key to [[The XBMC Database#movie|movie table]]
 +
|}
 +
 
 +
==== studiolinkmusicvideo ====
 +
This table links studios to music videos.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idStudio || integer || Foreign key to [[The XBMC Database#studio|studio table]]
 +
|-
 +
|idMVideo || integer || Foreign key to [[The XBMC Database#movievideo|movievideo table]]
 +
|}
 +
 
 +
==== tvshow ====
 +
This table stores information about a television series. Information concerning the shows episodes is stored in [[The XBMC Database#episode|episode]]. To link a TV show to its episodes, use [[The XBMC Database#tvshowlinkepisode|tvshowlinkepisode]].
 +
 
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idShow || integer || Primary Key
 +
|-
 +
|c00 || text ||  Show Title
 +
|-
 +
|c01 || text || Show Plot Summary
 +
|-
 +
|c02 || text ||  Status
 +
|-
 +
|c03 || text ||  Votes
 +
|-
 +
|c04 || text ||  Rating
 +
|-
 +
|c05 || text ||  First Aired
 +
|-
 +
|c06 || text ||  Thumbnail URL
 +
|-
 +
|c07 || text ||  [unknown - Spoof Thumbnail URL?]
 +
|-
 +
|c08 || text ||  Genre
 +
|-
 +
|c09 || text ||  Original Title
 +
|-
 +
|c10 || text ||  Episode Guide URL
 +
|-
 +
|c11 || text ||  Fan Art URL
 +
|-
 +
|c12 || text ||  SeriesId (when using thetvdb.com scraper)
 +
|-
 +
|c13 || text ||  Content Rating
 +
|-
 +
|c14 || text ||  Network
 +
|-
 +
|c15 || text ||  Title formatted for sorting
 +
|-
 +
|c16 || text ||  Not Used
 +
|-
 +
|c17 || text ||  Not Used
 +
|-
 +
|c18 || text ||  Not Used
 +
|-
 +
|c19 || text ||  Not Used
 +
|-
 +
|c20 || text ||  [unknown]
 +
|}
 +
 
 +
==== tvshowlinkepisode ====
 +
This table links TV shows (series) to episodes.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idShow || integer || Foreign Key to [[The XBMC Database#tvshow|tvshow table]]
 +
|-
 +
|idEpisode || integer || Foreign Key to [[The XBMC Database#episode|episode table]]
 +
|}
 +
 
 +
==== tvshowlinkpath ====
 +
This table links a TV show to its path.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idShow || integer || Foreign key to [[The XBMC Database#tvshow|tvshow table]]
 +
|-
 +
|idPath || integer || Foreign key to [[The XBMC Database#path|path table]]
 +
|}
 +
 
 +
==== version ====
 +
This table stores database information.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idVersion || integer || Version of database
 +
|-
 +
|idCompressCount || integer || Number of times database has been compressed
 +
|}
 +
 
 +
==== writerlinkepisode ====
 +
This table links writers to TV show episodes.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idWriter || integer || Foreign key to [[The XBMC Database#actors|actors table]]
 +
|-
 +
|idEpisode || integer || Foreign key to [[The XBMC Database#episode|episode table]]
 +
|}
 +
 
 +
==== writerlinkmovie ====
 +
This table links writers to movies.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idWriter || integer || Foreign key to [[The XBMC Database#actors|actors table]]
 +
|-
 +
|idMovie || integer || Foreign key to [[The XBMC Database#movie|movie table]]
 +
|}
 +
 
 +
== The View Modes Database ==
 +
XBMC can track a user's View Mode for every path, so you could browse movies using DVD Thumbs and browse TV shows using Fanart. This database contains the last view and sorting method a user chose for each path while navigating XBMC.
 +
 
 +
The View Modes database is stored in userdata/Database/ViewModes.db.
 +
 
 +
=== Tables ===
 +
The View Modes database uses only two tables. Most of the useful information is in [[The XBMC Database#view|view]].
 +
 
 +
==== version ====
 +
This table stores database information.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idVersion || integer || Version of database
 +
|-
 +
|idCompressCount || integer || Number of times database has been compressed
 +
|}
 +
 
 +
==== view ====
 +
This table stores details on the saved view mode for all known paths.
 +
{|class="wikitable"
 +
! Column Name || Data Type || Description
 +
|-
 +
|idView || integer || Primary Key
 +
|-
 +
|window || integer || Window GUI ID
 +
|-
 +
|path || text || Path to trigger the view on
 +
|-
 +
|viewMode || integer || View Mode
 +
|-
 +
|sortMethod || integer || ID of sort method
 +
|-
 +
|sortOrder || integer || Sort order (ascending or descending)
 +
|}
 +
 
 +
 
 +
==See also==
 +
* [[HOW-TO:Synchronize multiple XBMC libraries]]
  
[[Category:Skin Development]]
+
[[Category:Development]]
[[Category:Addon Development]]
+

Revision as of 20:03, 22 March 2013

Cleanup.png This page or section may require cleanup, updating, spellchecking, reformatting and/or updated images. Please improve this page if you can. The discussion page may contain suggestions.

Incomplete.png INCOMPLETE:
This page or section is incomplete. Please add information or correct uncertain data which is marked with a ?

XBMC uses SQLite, an open source light-weight SQL database-engine, to store all its library related data (Music, Video, and Program databases). By default, the database files (*.db) are stored in The UserData Folder, specifically in userdata/Database.

In addition to indexing media files when activated by user-selected Content settings, XBMC also puts a video in its database if you change any OSD setting while watching it. Resume points are stored in this database as well. These entries are added to the database whether the affected video is part of the Video Library or not.


Contents

1 Using the Databases

The XBMC databases are automatically maintained whenever you use XBMC. You can activate the most powerful database functionality by setting the Content property on all of your media sources, and using XBMC Library Mode. This view mode allows you to browse your media based on the details available in the databases, rather than using simple folder and filenames for details. You can read more about Library Mode for Music and Video files on their respective pages.

Since XBMC maintains the databases on its own, the only time a developer really needs to access the databases is for display information. The following sections discuss how you can access the information contained in the XBMC databases, and give some brief examples of how to use it.

1.1 Building SQL Queries

SQLite queries can be incredibly powerful (and extraordinarily complicated). If you are not already familiar with SQL syntax, it would probably be a good idea to check out a general tutorial, such as this one.

For most XBMC development projects, you're going to be doing select statements. "Select" is a SQL command used to gather data (in the form of "rows") out of a SQL database. Your select statement will include:

  • A list of all the data fields (columns in the database table) you want for each row.
  • A list of all the tables you need to get information from
  • A list of comparisons used to narrow down your results. This last component is optional, but it makes sure your results are relevant and is often used to link database entries across multiple tables.

Below are a few sample select statements, so you can see how it works.

This query grabs all of the information for every movie in the Video Library.

select * from movie

Note that "*" is used to indicate all fields. Also,there is no "where" clause in this statement, so it returns every row in the table.

This query narrows down the results to just those movies released in 2007.

select * from movie where c07 = 2007

Note that the column containing the movie's release year is labelled simply "c07." The tables further down this page help you find out which columns contain the information you're looking for.

This query example is more semantic. Lists your movies including, in this order, internal ID, internal file ID, rating, movie year, IMDB ID, movie name and movie plot.

select idMovie,idFile,c05,c07,c09,c00,c03,c02 from movie;

Now the following query is a bit more complex because it joins 3 movie-related tables (movie, files and path) to list a single useful view of your movies. In human language it lists movie ID, movie year, IMDB rating, IMDB ID, movie name and full path of the movie file, ordered by IMDB rating with highest rating appearing first:

 select idMovie,c07,c05,c09,c00,path.strPath||files.strFilename from movie, files,path where movie.idFile=files.idFile and files.idPath=path.idPath order by c05 desc;

You could also use less than or greater than symbols to get newer or older movies.

This query gets just the path and filename of all of the video files from season two of Chuck.


If you're not familiar with SQL queries, this query probably looks pretty complicated. It serves as a good demonstration of why there are so many tables in the list below, and how to use them. Many of the elements of a TV show's path and filename and used repeatedly, so SQL allows us to save space and speed up our searches by storing each of those elements just once, in one place, and referencing them repeatedly by the same ID.

In this case, the root path that contains your video files is a long string that repeats at the beginning of many files. The name of a TV series, too, is repeated in every single episode of that series, so it makes the most sense to save the series name once (along with all information relevant to the series). We do that in the table tvshow, and every episode of the TV show can access all of that information using just the TV show's ID.

1.2 Accessing the Databases with a SQLite application

Database files can be transferred via FTP to a Windows-based computer and edited or analysed with a SQLite graphical client. XBMC's version of the database engine should be compatible with the standard clients such as SQLiteBrowser or SQLiteCC, (more available management-tools can be found in sqlite.org WIKI).
We recommend you use SQLiteSpy version 1.5.2 or higher.

These applications are generally quite powerful. Once you find one you like, you can easily browse the XBMC databases. This is probably the best way to make modifications to the Video or Music Library.

1.3 Accessing the Databases with XBMC Python

Many Python plugins (and some scripts) can use the information in the XBMC database to offer users additional convenience and functionality. The easiest way to access the XBMC database via XBMC Python is using JSON RPC

2 The Music Library

This database contains all information concerning music files that you've added to the Music Library. It is used in the Music portion of XBMC.

The music database is stored in userdata/Database/MyMusic7.db

2.1 Views

Views are standard queries, often long or complicated queries saved in the database for convenience. The views below allow you to easily access all the information about songs and albums in the Music Library, across all the linking tables.

2.1.1 albumview

A view that joins album to artist, genre, thumb, and albuminfo.

2.1.2 artistview

A view that joins artist to artistinfo.

2.1.3 songview

A view that joins song to album, path, artist, genre, thumb, and karaokedata.

2.2 Tables

2.2.1 album

This table contains basic album information.

Column Name Data Type Description
idAlbum integer Primary Key
strAlbum varchar(256) Album Name
strArtists text Artist Name
strGenres text Album Genre
iYear integer Album Year
idThumb integer Foreign key to thumb table
bCompilation integer [unknown]

2.2.2 album_artist

Column Name Data Type Description
idArtist integer Primary Key
idAlbum integre [unknown]
boolFeatured integer [unknown]
iOrder integer [unknown]

2.2.3 album_genre

Column Name Data Type Description
idGenre integer Primary Key
idAlbum integer [unknown]
iOrder integer [unknown]

2.2.4 albuminfo

This table contains additional information about an album, such as Rating, Moods, Styles, Reviews, Image URL, and type.

Column Name Data Type Description
idAlbumInfo integer Primary Key
idAlburm integer Foreign key
iYear integer Album Year
strMoods text [unknown]
strStyles text [unknown]
strThemes text [unknown]
strReview text [unknown]
strImage text [unknown]
strLabel text [unknown]
strType text [unknown]
iRating integer [unknown]

2.2.5 albuminfosong

This table links songs to albums and stores the duration of each track.

Column Name Data Type Description
idAlbumInfoSong integer Primary Key
idAlbumInfo integer Foreign Key
iTrack integer [unknown]
strTitle text [unknown]
iDuration integer [unknown]

2.2.6 art

Column Name Data Type Description
art_id integer Primary Key
media_id integer [unknown]
media_type text [unknown]
type text [unknown]
url text [unknown]

2.2.7 artist

This table stores the name of each artist.

Column Name Data Type Description
idArtist integer Primary Key
strArtist varchar(256) [unknown]

2.2.8 artistinfo

This tables stores relevant information about each artist, such as when they were born, Fan Art URL's, biographical information, etc.

Column Name Data Type Description
idArtistInfo integer Primary Key
idArtist integer Foreign Key
strBorn text [unknown]
strFormed text [unknown]
strGenres text [unknown]
strMoods text [unknown]
strStyles text [unknown]
strInstruments text [unknown]
strBiography text [unknown]
strDied text [unknown]
strDisbanded text [unknown]
strYearsActive text [unknown]
strImage text [unknown]
strFanart text [unknown]

2.2.9 content

This table is related to the scraper.

Column Name Data Type Description
strPath text [unknown]
strScraperPath text [unknown]
strContent text [unknown]
strSettings text [unknown]

2.2.10 discography

Links albums to artists with the year produced.

2.2.11 exartistablum

Links artists to albums

2.2.12 exartistsong

Links artists to songs

2.2.13 exgenrealbum

Links genres to albums

2.2.14 exgenresong

Links genres to songs

2.2.15 genre(music)

This table contains genre titles.

2.2.16 karaokedata

This table contains karaoke specific information for certain songs

2.2.17 path(music)

This table contains paths and hashes of files in the Music Database.

2.2.18 song

This table contains song information such as Name, Track Title, MusicBrainz information, times played, last played, rating, etc.

2.2.19 thumb

Column Name Data Type Description
idThumb integer Primary Key
strThumb text [unknown]

2.2.20 version(music)

Column Name Data Type Description
idVersion integer Version of the music database
idCompressCount integer Compression Count?

3 The Video Library

This database contains all information concerning TV shows, movies, and music videos. It is used in the Videos portion of XBMC.

The video database is stored in userdata/Database/MyVideos60.db.

3.1 Views

Views are standard queries, often long or complicated queries saved in the database for convenience. The views below allow you to easily access all the information about each of the main media types in the Video Library, across all the linking tables.

3.1.1 episodeview

A view that joins episode to file and tvshow (through tvshowlinkepisode) and path.

3.1.2 movieview

A view that joins movie to file and path.

3.1.3 musicvideoview

A view that joins musicvideo to file and path.

3.1.4 tvshowview

View that joins tvshow to path. Also produces information about total number of episodes as well as number of watched and unwatched episodes.

3.2 Tables

The information in the Video Library is organized into the following tables. Several large tables (such as episode, movie, settings, and tvshow) contain the bulk of the information, while most of the others are used to link a long string to a common ID key.

3.2.1 actorlinkepisode

This table links actors to episodes and stores role information.

Column Name Data Type Description
idActor integer Foreign key to actors table
idEpisode integer Foreign key to episode table
strRole text Role the actor played in this episode

3.2.2 actorlinkmovie

This table links actors to movies and stores role information.

Column Name Data Type Description
idActor integer Foreign key to actors table
idMovie integer Foreign key to movie table
strRole text Role the actor played in this movie

3.2.3 actorlinktvshow

This table links actors to TV shows and stores role information.

Column Name Data Type Description
idActor integer Foreign key to actors table
idShow integer Foreign key to tvshow table
strRole text Role the actor played in this TV show

3.2.4 actors

This table stores actor, artist, director, and writer information.

Column Name Data Type Description
idActor integer Primary Key
strActor integer Name of the actor, artist, director, or writer
strThumb text Thumbnail URL

3.2.5 art

This table stores URLs for video art metadata.

Column Name Data Type Description
art_id integer Primary Key
media_id integer The id of the media this piece of art is for
media_type text The type of media this art applies to - movie, set, tvshow, season, episode, musicvideo or actor
type text The image type - poster, fanart, thumb, banner, landscape, clearlogo, clearart, characterart or discart
url text Thumbnail URL

3.2.6 artistlinkmusicvideo

This table links artists to music videos.

Column Name Data Type Description
idArtist integer Foreign key to actors table
idMVideo integer Foreign key to musicvideo table

3.2.7 bookmark

This table stores bookmarks, which are timestamps representing the point in a video where a user stopped playback, an explicit bookmark requested by the user, or an automatically generated episode bookmark.

Column Name Data Type Description
idBookmark integer Primary Key
idFile integer Foreign key to files table
timeInSeconds double Time in seconds of bookmark location
totalTimeInSeconds integer Time in seconds of the video
thumbNailImage text Thumbnail for bookmark
player text Player used to store bookmark
playerState text Player's internal state in XML
type integer Type of bookmark (0=standard, 1=resume, 2=episode

3.2.8 directorlinkepisode

This table links directors to TV show episodes.

Column Name Data Type Description
idDirector integer Foreign key to actors table
idEpisode integer Foreign key to episode table
strRole text [Appears to be unused]

3.2.9 directorlinkmovie

This table links directors to movies.

Column Name Data Type Description
idDirector integer Foreign key to actors table
idMovie integer Foreign key to movie table

3.2.10 directorlinkmusicvideo

This table links directors to music videos.

Column Name Data Type Description
idDirector integer Foreign key to actors table
idMVideo integer Foreign key to musicvideo table

3.2.11 directorlinktvshow

This table links directors to TV shows.

Column Name Data Type Description
idDirector integer Foreign key to actors table
idShow integer Foreign key to tvshow table

3.2.12 episode

This table stores television episode information. Information concerning the series is stored in tvshow. To link an episode to its parent series, use tvshowlinkepisode.

Column Name Data Type Description
idEpisode integer Primary Key
c00 text Episode Title
c01 text Plot Summary
c02 text [unknown - listed as Votes]
c03 text Rating
c04 text Writer
c05 text First Aired
c06 text Thumbnail URL
c07 text [unknown - listed as Thumbnail URL Spoof, unused?]
c08 text Has the episode been watched? (unused?)
c09 text Episode length in minutes
c10 text Director
c11 text [unknown - listed as Indentifier]
c12 text Season Number
c13 text Episode Number
c14 text [unknown - listed as Original Title, unused?]
c15 text Season formatted for sorting
c16 text Episode formatted for sorting
c17 text Bookmark
c18 text Not used
c19 text Not used
c20 text Not used
idFile integer Foreign key to the files table

3.2.13 files

This table stores filenames and links the path.

Column Name Data Type Description
idFile integer Primary Key
idPath integer Foreign key to path table
strFilename text Full name of file including extension
playCount integer
lastPlayed text

3.2.14 genre

This table stores genre information. For convenience the contents are duplicated in movie and tvshow, so a join isn't necessary.

Column Name Data Type Description
idGenre integer Primary Key
strGenre text Genre label

3.2.15 genrelinkmovie

This table links genres to movies. (The contents are also stored in movies.c14, though.)

Column Name Data Type Description
idGenre integer Foreign key to genre table
idMovie integer Foreign key to movie table

3.2.16 genrelinkmusicvideo

This table links genres to music videos.

Column Name Data Type Description
idGenre integer Foreign key to genre table
idMVideo integer Foreign key to musicvideo table

3.2.17 genrelinktvshow

This table links genres to TV show. (The contents are also stored in tvshow.c08, though.)

Column Name Data Type Description
idGenre integer Foreign key to genre table
idShow integer Foreign key to tvshow table

3.2.18 movie

This table stores movie information.

Column Name Data Type Description
idMovie integer Primary Key
c00 text Local Movie Title
c01 text Movie Plot
c02 text Movie Plot Outline
c03 text Movie Tagline
c04 text Rating Votes
c05 text Rating
c06 text Writers
c07 text Year Released
c08 text Thumbnails
c09 text IMDB ID
c10 text Title formatted for sorting
c11 text Runtime (UPnP devices see this as seconds)
c12 text MPAA Rating
c13 text IMDB Top 250 Ranking
c14 text Genre
c15 text Director
c16 text Original Movie Title
c17 text [unknown - listed as Thumbnail URL Spoof]
c18 text Studio
c19 text Trailer URL
c20 text Fanart URLs
c21 text Country (Added in r29886[1])
c23 text idPath
idFile integer Foreign Key to files table

3.2.19 movielinktvshow

This table links movies to TV shows.

Column Name Data Type Description
idMovie integer Foreign key to movie table
idShow integer Foreign key to tvshow table

3.2.20 musicvideo

Column Name Data Type Description
idMVideo integer Primary Key
c00 text Title
c01 text Thumbnail URL
c02 text [unknown - listed as Thumbnail URL spoof]
c03 text Play count (unused?)
c04 text Run time
c05 text Director
c06 text Studios
c07 text Year
c08 text Plot
c09 text Album
c10 text Artist
c11 text Genre
c12 text Track
idFile integer Foreign Key to files table

3.2.21 path

This table stores path information.

Column Name Data Type Description
idPath integer Primary Key
strPath text Path URL
strContent text Type of content (tvshows, movies, etc...)
strScraper text XML file of scraper used for this path
strHash text Hash
scanRecursive integer Recursive scan setting
useFolderNames bool User folder names setting
strSettings text Custom settings used by scraper

3.2.22 seasons

This table stores the links between tv show and seasons.

Column Name Data Type Description
idSeason integer Primary Key
idShow integer Foreign key to tvshow table
season integer Season number

3.2.23 sets

This table stores the id and name for movie sets. Sets are linked to movies in the movie table (idSet column).

Column Name Data Type Description
idSet integer Primary Key
strSet text The name of the set

3.2.24 settings

This table stores settings for individual files.

Column Name Data Type Description
idFile integer Foreign Key to files table
Interleaved bool Interleaved
Nocache bool NoCache
Deinterlace bool Deinterlace
FilmGrain integer FilmGrain
ViewMode integer ViewMode
ZoomAmount float ZoomAmount
PixelRatio float PixelRatio
AudioStream integer Selected audio stream
SubtitleStream integer Selected subtitle stream
SubtitleDelay float Amount of delay for subtitles
SubtitleOn bool Enable subtitles
Brightness integer Brightness
Contrast integer Contrast
Gamma integer Gamma
VolumeAmplification float VolumeAmplification
AudioDelay float AudioDelay
OutputToAllSpeakers bool OutputToAllSpeakers
ResumeTime integer ResumeTime
Crop bool Crop
CropLeft integer CropLeft
CropRight integer CropRight
CropTop integer CropTop
CropBottom integer CropBottom

3.2.25 stacktimes

This table stores playing times for files (used for playing multi-file videos).

Column Name Data Type Description
idFile integer Foreign key to files table
times text Times

3.2.26 streamdetails

This table contains information regarding codecs used, aspect ratios etc

Column Name Data Type Description
idFile integer Foreign Key to files table
iStreamType integer 0 = video, 1 = audio, 2 = subtitles
strVideoCodec text Video codex (xvid etc)
fVideoAspect real Aspect ratio
iVideoWidth integer Width of the video
iVideoHeight integer Height of the video
strAudioCodec text Audio codec (aac, mp3 etc)
iAudioChannels integer Number of audio channels (2 for stereo, 6 for 5.1 etc)
strAudioLanguage text Language of the audio track
strSubtitleLanguage text Language of the subtitles

3.2.27 studio

This table stores studio information.

Column Name Data Type Description
idStudio integer Primary Key
strStudio text Studio Label

3.2.28 studiolinkmovie

This table links studios to movies.

Column Name Data Type Description
idStudio integer Foreign key to studio table
idMovie integer Foreign key to movie table

3.2.29 studiolinkmusicvideo

This table links studios to music videos.

Column Name Data Type Description
idStudio integer Foreign key to studio table
idMVideo integer Foreign key to movievideo table

3.2.30 tvshow

This table stores information about a television series. Information concerning the shows episodes is stored in episode. To link a TV show to its episodes, use tvshowlinkepisode.

Column Name Data Type Description
idShow integer Primary Key
c00 text Show Title
c01 text Show Plot Summary
c02 text Status
c03 text Votes
c04 text Rating
c05 text First Aired
c06 text Thumbnail URL
c07 text [unknown - Spoof Thumbnail URL?]
c08 text Genre
c09 text Original Title
c10 text Episode Guide URL
c11 text Fan Art URL
c12 text SeriesId (when using thetvdb.com scraper)
c13 text Content Rating
c14 text Network
c15 text Title formatted for sorting
c16 text Not Used
c17 text Not Used
c18 text Not Used
c19 text Not Used
c20 text [unknown]

3.2.31 tvshowlinkepisode

This table links TV shows (series) to episodes.

Column Name Data Type Description
idShow integer Foreign Key to tvshow table
idEpisode integer Foreign Key to episode table

3.2.32 tvshowlinkpath

This table links a TV show to its path.

Column Name Data Type Description
idShow integer Foreign key to tvshow table
idPath integer Foreign key to path table

3.2.33 version

This table stores database information.

Column Name Data Type Description
idVersion integer Version of database
idCompressCount integer Number of times database has been compressed

3.2.34 writerlinkepisode

This table links writers to TV show episodes.

Column Name Data Type Description
idWriter integer Foreign key to actors table
idEpisode integer Foreign key to episode table

3.2.35 writerlinkmovie

This table links writers to movies.

Column Name Data Type Description
idWriter integer Foreign key to actors table
idMovie integer Foreign key to movie table

4 The View Modes Database

XBMC can track a user's View Mode for every path, so you could browse movies using DVD Thumbs and browse TV shows using Fanart. This database contains the last view and sorting method a user chose for each path while navigating XBMC.

The View Modes database is stored in userdata/Database/ViewModes.db.

4.1 Tables

The View Modes database uses only two tables. Most of the useful information is in view.

4.1.1 version

This table stores database information.

Column Name Data Type Description
idVersion integer Version of database
idCompressCount integer Number of times database has been compressed

4.1.2 view

This table stores details on the saved view mode for all known paths.

Column Name Data Type Description
idView integer Primary Key
window integer Window GUI ID
path text Path to trigger the view on
viewMode integer View Mode
sortMethod integer ID of sort method
sortOrder integer Sort order (ascending or descending)


5 See also

Personal tools
Namespaces

Variants
Actions
Navigation
Wiki help
Toolbox