SmartPlaylists (1.1.4.6) | Page 7

Discussion in 'MediaPortal 1 Plugins' started by fabien44, August 26, 2008.

    • Premium Supporter

    FillR MP Donator

    System Specs
    Re: SmartPlaylists (1.1.3)

    Hi Fabien44,

    Yes, I'm using a remote, that's why I think we should have a form with "list of value" fields. (if possible in MP)

    A kind of form with:

    Interpret: |list of value | and/or (Pick one button) Genre:|list of value of all genres in the database|

    and/or Interpret 2 |list of value of all interprets in the db| and/or interpret3 |list of value of all interprets in the db|

    and/or Year |list of all years| and/or Comment: |list of value of all distinct comments|

    Limit : a Counter ....

    <Start Play> A button allowing to build the SQL statement, execute it, insert the datas in the playlist and start to play

    In fact, no typing required, all the elements will be retrieved from a select distinct xxx from the database.
    • Team MediaPortal

    DieBagger Documentation Group

    System Specs
    Re: SmartPlaylists (1.1.3)

    Hi Fabien,

    is the sourcecode for this plugin available? I need to add playlist handling to the wifiremote plugin and it would be nice to have some code examples... ;)

    :D
  1. fabien44 Thread Starter Portal Pro

    Re: SmartPlaylists (1.1.3)

    Hi DieBagger,

    yes the source code is provided in the zip file of the plugin!
    • Like Like x 1
    • Team MediaPortal

    DieBagger Documentation Group

    System Specs
    Re: SmartPlaylists (1.1.3)

    Should have checked that, thx!
  2. PABeaver Portal Member

    Re: SmartPlaylists (1.1.3)

    Most of these fields are self explanatory. Does one of these fields include the comments? I have a fair amount of tracks that are tagged "explicit" or "Christmas" and I would love to build my playlists with =! "Christmas" in the script. If these fields do not include the comments from the IDtag is there another way I could do this?

    Thanks for the great plugin!
  3. fabien44 Thread Starter Portal Pro

    Re: SmartPlaylists (1.1.3)

    Did you try with strComment, strComments, comments or comment field?
  4. mysteryboard Portal Member

    AW: SmartPlaylists (1.1.3)

    I tryed strComment, strComments, comments or comment field, but it wasn't possible to select anything. Furher on it wasn't possible to create a query with the field strComposer. I know, that these fields are part of the music database. Is it necessary to expand the functionallity of your plugin?

    Thanx

    Here is an example of my playlist:
    <smartPlaylist name="100 zufällige BeBop-Songs" query="WHERE strComment like '| %BeBop% |' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
  5. fabien44 Thread Starter Portal Pro

    Re: SmartPlaylists (1.1.3)

    Hi,

    i have checked that not every field must be surrounded with |, only strArtist / strAlbumArtist / strGenre / strComposer fields (i update post #1 with all fields available).

    So your query should work with this syntax:
    <smartPlaylist name="100 zufällige BeBop-Songs" query="WHERE strComment like '%BeBop%' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
  6. mysteryboard Portal Member

    AW: SmartPlaylists (1.1.3)

    Thank you for your answer. I'll check your syntax-tipp.:)

    Hi Fabien,

    sorry!

    The syntax

    <smartPlaylist name="100 zufällige BeBop-Songs" query="WHERE strComment like '%BeBop%' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>

    didn't work. Only a popup with a wait-message happens. I have checked my tags with mptagthat, and all my tracks are ok. Do you have an other idea?

    Greetings:confused:
  7. mysteryboard Portal Member

    AW: SmartPlaylists (1.1.3)

    Hello,

    I tried a lot of things to find a best way to work with the smart playlists. I have my own special flag for party-music in the field comments. But it isn't possible to ceate a select including this field. So I wrote this flag in composer. StrComposer mustn't be surrounded with symbol |, this is wrong in post # 1. I want to send you my SQL-Queries for my special playlists. Maybe somebody can work with my statements as a basic for the own playlists. Please send me your smart playlists, when you want.

    <?xml version="1.0" encoding="utf-8"?>
    <rootElement>
    <smartPlaylist name="50 random Songs added in the last 2 Weeks" query="WHERE dateAdded >= date('now','-15 day') ORDER BY RANDOM() LIMIT 50"></smartPlaylist>
    <smartPlaylist name="100 random Songs played very often last month" query="WHERE dateLastPlayed >= date('now','-30 day') ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
    <smartPlaylist name="Party - Rock/Folk - Hits first" query="WHERE strComposer like '%Party%' and (strGenre like '| %Rock% |' or strGenre like '| %Folk% |') ORDER BY iYear desc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Rock/Folk - Oldies first" query="WHERE strComposer like '%Party%' and (strGenre like '| %Rock% |' or strGenre like '| %Folk% |') ORDER BY iYear asc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Rock/Folk - sort by Artist" query="WHERE strComposer like '%Party%' and (strGenre like '| %Rock% |' or strGenre like '| %Folk% |') ORDER BY strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Pop - Hits first" query="WHERE strComposer like '%Party%' and (strGenre like '| %Pop% |' or strGenre like '| %World% |' or strGenre like '| %Sound% |' or strGenre like '| %R&amp;B% |') ORDER BY iYear desc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Pop - Oldies first" query="WHERE strComposer like '%Party%' and (strGenre like '| %Pop% |' or strGenre like '| %World% |' or strGenre like '| %Sound% |' or strGenre like '| %R&amp;B% |') ORDER BY iYear asc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Pop - sort by Artist" query="WHERE strComposer like '%Party%' and (strGenre like '| %Pop% |' or strGenre like '| %World% |' or strGenre like '| %Sound% |' or strGenre like '| %R&amp;B% |') ORDER BY strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Funk/Soul/RAP/R&amp;B/HIP-Hop/DISCO - Hits first" query="WHERE strComposer like '%Party%' and (strGenre like '| %RAP% |' or strGenre like '| %R&amp;B% |' or strGenre like '| %HIP% |' or strGenre like '| %Soul% |' or strGenre like '| %Disco% |' or strGenre like '| %Funk% |' or strGenre like '| %Schlager% |' or strGenre like '| %Reggae% |') ORDER BY iYear desc,
    strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Funk/Soul/RAP/R&amp;B/HIP-Hop/DISCO - Oldies first" query="WHERE strComposer like '%Party%' and (strGenre like '| %RAP% |' or strGenre like '| %R&amp;B% |' or strGenre like '| %HIP% |' or strGenre like '| %Soul% |' or strGenre like '| %Disco% |' or strGenre like '| %Funk% |' or strGenre like '| %Schlager% |' or strGenre like '| %Reggae% |') ORDER BY iYear asc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Funk/Soul/RAP/R&amp;B/HIP-Hop/DISCO - Artist" query="WHERE strComposer like '%Party%' and (strGenre like '| %RAP% |' or strGenre like '| %R&amp;B% |' or strGenre like '| %HIP% |' or strGenre like '| %Soul% |' or strGenre like '| %Disco% |' or strGenre like '| %Funk% |' or strGenre like '| %Schlager% |' or strGenre like '| %Reggae% |') ORDER BY strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Punk/Hard/Metal - Hits first" query="WHERE strComposer like '%Party%' and (strGenre like '| %Metal% |' or strGenre like '| %Mittel% |' or strGenre == '| Hard Rock |' or strGenre like '| %Alternative% |' or strGenre like '| %Grunge% |' or strGenre like '| %core% |' or strGenre like '| %Punk% |') ORDER BY iYear desc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Punk/Hard/Metal - Oldies first" query="WHERE strComposer like '%Party%' and (strGenre like '| %Metal% |' or strGenre like '| %Mittel% |' or strGenre == '| Hard Rock |' or strGenre like '| %Alternative% |' or strGenre like '| %Grunge% |' or strGenre like '| %core% |' or strGenre like '| %Punk% |') ORDER BY iYear asc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Punk/Hard/Metal - sort by Artist" query="WHERE strComposer like '%Party%' and (strGenre like '| %Metal% |' or strGenre like '| %Mittel% |' or strGenre == '| Hard Rock |' or strGenre like '| %Alternative% |' or strGenre like '| %Grunge% |' or strGenre like '| %core% |' or strGenre like '| %Punk% |') ORDER BY strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - NDW/Wave/Grunge/Indie/Altern. - Hits first" query="WHERE strComposer like '%Party%' and (strGenre like '| %Indie% |' or strGenre like '| %Alternative% |' or strGenre like '| %Grunge% |' or strGenre like '| %core% |' or strGenre like '| %NDW% |' or strGenre like '| %Wave% |') ORDER BY iYear desc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - NDW/Wave/Grunge/Indie/Altern. - sort by Genre" query="WHERE strComposer like '%Party%' and (strGenre like '| %Indie% |' or strGenre like '| %Alternative% |' or strGenre like '| %Grunge% |' or strGenre like '| %core% |' or strGenre like '| %NDW% |' or strGenre like '| %Wave% |') ORDER BY strGenre asc, iYear desc"></smartPlaylist>
    <smartPlaylist name="Party - NDW/Wave/Grunge/Indie/Altern. - sort by Artist" query="WHERE strComposer like '%Party%' and (strGenre like '| %Indie% |' or strGenre like '| %Alternative% |' or strGenre like '| %Grunge% |' or strGenre like '| %core% |' or strGenre like '| %NDW% |' or strGenre like '| %Wave% |') ORDER BY strArtist asc, strAlbum asc"></smartPlaylist>
    <smartPlaylist name="Party - Gothic/Industrial - sort by Genre" query="WHERE strComposer like '%Party%' and (strGenre like '| %Indust% |' or strGenre like '| %Gothic% |') ORDER BY StrGenre asc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Gothic/Industrial - sort by Artist" query="WHERE strComposer like '%Party%' and (strGenre like '| %Indust% |' or strGenre like '| %Gothic% |') ORDER BY StrArtist asc, strAlbum asc"></smartPlaylist>
    <smartPlaylist name="Party - Techno-Dance" query="WHERE strComposer like '%Party%' and (strGenre like '| %Dance% |' or strGenre like '| %Techno% |' or strGenre like '| %Electronica% |') ORDER BY strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Folk/Country" query="WHERE strComposer like '%Party%' and (strGenre like '| %Folk% |' or strGenre like '| %Country% |') ORDER BY iYear desc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Soundtrack/World" query="WHERE strComposer like '%Party%' and (strGenre like '| %Soundtrack% |' or strGenre like '| %World% |') ORDER BY strGenre asc, iYear desc"></smartPlaylist>
    <smartPlaylist name="Party - Latin/Reggae" query="WHERE strComposer like '%Party%' and (strGenre like '| %Latin% |' or strGenre like '| %Reggae% |') ORDER BY strGenre asc, strArtist asc"></smartPlaylist>
    <smartPlaylist name="Party - Salsa" query="WHERE strComposer like '%Party%' and strGenre like '| %Salsa% |' ORDER BY iRating desc"></smartPlaylist>
    <smartPlaylist name="Party - Merengue" query="WHERE strComposer like '%Party%' and strGenre like '| %Merengue% |' ORDER BY iRating desc"></smartPlaylist>
    <smartPlaylist name="Party - Bachata" query="WHERE strComposer like '%Party%' and strGenre like '| %Bachata% |' ORDER BY iRating desc"></smartPlaylist>
    <smartPlaylist name="100 random Alternative- and Indie-Songs" query="WHERE strGenre == '| Indie |' or strGenre == '| Alternative |' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
    <smartPlaylist name="100 random Songs Hard Rock" query="WHERE strGenre == '| Hard Rock |' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
    <smartPlaylist name="100 random Songs Rock (inc. Hard- and Punkrock)" query="WHERE strGenre like '| %Rock% |' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
    <smartPlaylist name="100 random Songs Metal" query="WHERE strGenre like '| %Metal% |' or strGenre like '| %Mittel% |' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
    <smartPlaylist name="Oldies from the 70th and 80th or older" query="WHERE iYear &lt; 1990 ORDER BY RANDOM() LIMIT 200"></smartPlaylist>
    <smartPlaylist name="100 random Songs Pop" query="WHERE strGenre like '| %Pop% |' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
    <smartPlaylist name="100 random Songs Progressive" query="WHERE strGenre like '| %Progressive% |' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
    <smartPlaylist name="100 random Songs Gothic/Industrial" query="WHERE strGenre like '| %Indust% |' or strGenre like '| %Gothic% |' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
    <smartPlaylist name="50 random Songs POP-/ Techno-Dance" query="WHERE strGenre like '| %Dance% |' or strGenre like '| %Techno% |' ORDER BY RANDOM() LIMIT 50"></smartPlaylist>
    <smartPlaylist name="50 random Songs Folk and Country" query="WHERE strGenre like '| %Folk% |' or strGenre like '| %Country% |' ORDER BY RANDOM() LIMIT 50"></smartPlaylist>
    <smartPlaylist name="50 random Songs RAP, R&amp;B, HIP-Hop" query="WHERE strGenre like '| %RAP% |' or strGenre like '| %R&amp;B% |' or strGenre like '| %HIP% |' ORDER BY RANDOM() LIMIT 50"></smartPlaylist>
    <smartPlaylist name="100 random Songs ChillOut and World" query="WHERE strGenre == '| Electronica |' or strGenre == '| Chill Out |' or strGenre == '| World |' and strArtist != '| Xavier Naidoo |' and strArtist != '| Harald Juhnke |' and strAlbum != '| Joy of the World |' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
    <smartPlaylist name="100 random Ballads" query="WHERE strConductor like '%Ballade%' ORDER BY RANDOM() LIMIT 100"></smartPlaylist>
    <smartPlaylist name="Songs from 2011" query="WHERE iYear == 2011 ORDER BY strArtist asc"></smartPlaylist>
    <smartPlaylist name="Songs from 2010" query="WHERE iYear == 2010 ORDER BY strArtist asc"></smartPlaylist>
    </rootElement>

Share This Page

Users Viewing Thread (Users: 0, Guests: 0)

Running the latest version?

V1.3.0 FINAL - released March 2013
Releasenews | Download
Changelog
 | Requirements
HTPC
Team-MediaPortal
 
About
Contact |  Press
Partners