[WiP] Centralised database in My Video, My Pictures and folder settings (1 Viewer)

regeszter

Retired Team Member
  • Premium Supporter
  • October 29, 2005
    5,335
    4,954
    Home Country
    Hungary Hungary

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    16,039
    11,112
    Kyiv
    Home Country
    Ukraine Ukraine
    If i'm right it needs to rewrite FH to use plugin APIs.
    Directly to the database, it refers only to the database, mvCentral and serials. And works directly with FH database.
     

    Edalex

    Community Plugin Dev
  • Premium Supporter
  • January 3, 2008
    2,959
    1,270
    Saratov
    Home Country
    Russian Federation Russian Federation
    Nope, mptvseries and movpics handling is right - DBSeries.GetAll() and DBMovies smth...
     

    ltfearme

    Community Plugin Dev
  • Premium Supporter
  • June 10, 2007
    6,755
    7,200
    Sydney
    Home Country
    Australia Australia
    Trakt uses the following API calls with no SQL as parameters:
    Code:
    public static void SetMovieInfoById(int lMovieId, ref IMDBMovie details);
    public static void SetMovieWatchedStatus(int iMovieId, bool watched, int percent);
    public static int GetFile(string strFilenameAndPath, out int lPathId, out int lMovieId, bool bExact);
    public static bool GetmovieWatchedStatus(int iMovieId, out int percent, out int timesWatched);
    public static void SetMovieWatchedCount(int movieId, int watchedCount);
    public static void SetMovieWatchedStatus(int iMovieId, bool watched, int percent);
    public static int GetMovieInfo(string strFilenameAndPath, ref IMDBMovie details);
    public static int GetMovieId(string strFilenameAndPath);
    public static int GetMovieStopTime(int iFileId);
    public static void SetMovieStopTime(int iFileId, int stoptime);
    public static void GetMovies(ref ArrayList movies);

    There is one public method I use which does take SQL, its only used in the configuration dialog so people can select which movies to restrict by Title or Path. It wouldn't be a big deal if I had to change this as it wont affect the everyday use of the plugin and im sure I can find another way to do what I want.
    Code:
    public static SQLiteResultSet GetResults(string sql);

    The SQL I use is the following:
    Code:
    SELECT movieinfo.strTitle, path.strPath, files.strFilename 
    FROM movieInfo
    LEFT JOIN files
    ON movieInfo.idMovie=files.idMovie
    LEFT JOIN path
    ON files.idPath=path.idPath
    ORDER BY strTitle
     

    regeszter

    Retired Team Member
  • Premium Supporter
  • October 29, 2005
    5,335
    4,954
    Home Country
    Hungary Hungary
    Trakt uses the following API calls with no SQL as parameters:

    All should work if I did not make any mistake. ;)

    There is one public method I use which does take SQL, its only used in the configuration dialog so people can select which movies to restrict by Title or Path. It wouldn't be a big deal if I had to change this as it wont affect the everyday use of the plugin and im sure I can find another way to do what I want.

    :)
     

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    16,039
    11,112
    Kyiv
    Home Country
    Ukraine Ukraine
    Erorrs in log file :mad:
    MySQL server 192.168.0.100
    Password for root - MediaPortal
     

    regeszter

    Retired Team Member
  • Premium Supporter
  • October 29, 2005
    5,335
    4,954
    Home Country
    Hungary Hungary
    MediaPortal.Video.Database.SqlServer.VideoDatabaseADO.CreateDb() MySql.Data.MySqlClient.MySqlException (0x80004005): Access denied for user 'root'@'192.168.0.1' (using password: YES)

    Password or mysql rights error.

    You may install a stand alone TvServer to the host which will be installed with right setup. You can uninstall it later.
     

    Users who are viewing this thread

    Top Bottom