Help - Search - Members - Calendar
Full Version: foo_playlist_tree
Hydrogenaudio Forums > Hosted Forums > foobar2000 > 3rd Party Plugins - (fb2k)
Pages: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37
cwbowron
QUOTE(Cornie @ Aug 29 2006, 16:18) *

QUOTE(cwbowron @ Aug 25 2006, 10:55) *


I haven't really processed your whole post yet, but why not just using one query that sorts them into rating rather 5 separate queries?



Ya... kinda where I went first... but then, only the Rating levels that actually returned results would show...
i.e. the pic I'd posted shows 0 items for So So... & Trash - These don't show using this method...

So, anyway, have you processed my whole post as yet?


You're best bet, is to just use %_name% for the folder display variable, and set the name of your 5 rating queries to "Favorites @format<%_itemcount%>", etc.
Cornie
QUOTE(cwbowron @ Aug 29 2006, 13:27) *


You're best bet, is to just use %_name% for the folder display variable, and set the name of your 5 rating queries to "Favorites @format<%_itemcount%>", etc.


Hmmmm.... seem to remember trying that as well and each query name was displayed literaly

+Favorites @format<%_itemcount%>
+Very Good @format<%_itemcount%>
+Good @format<%_itemcount%>
..
..

but, as I'm at the library (not at home) and can't quite remember - so I'll give it a shot when I get home...

btw... shouldn't %_itemcount% be quoted?
oh, and thanks for the prompt reply....

BLAH.... ok, so my memory fails.... right you were, thanks again for the help!

but I still think there's something wonky about the way $parent() & %_itemcount% interact...
gob
i thought of a few small things that might improve this component. first, if the playback order is set to shuffle, the first track played when sending to the playlist should follow this rule. also, can there be an option to not automatically select the tracks that are sent to the playlist?
tberman333
I have tried to set the double-click action on this plugin to be "Edit Other/Add to Specified Playlist" The problem is, when you do that there is no place to specify the playlist you want to send to. Would there be anyway to add an option to define a specifed playlist to add tracks to if you select that option as an action?

Thanks!
Fitret
QUOTE(Dr.Death @ Aug 15 2006, 00:07) *

Very usefull plugin, thx!
but NOT last_played MISSING didn't work 8\ what's wrong?


I'm having similar issues. NOT play_count MISSING doesn't work for me. If I put it in, no files show up. I'm trying to make a Most Played albums list by using $avg, and I'm having trouble figuring out the script. I mostly copied the $avg rating script posted earlier, but it's not quite working.
cwbowron
QUOTE(Fitret @ Sep 5 2006, 21:13) *

QUOTE(Dr.Death @ Aug 15 2006, 00:07) *

Very usefull plugin, thx!
but NOT last_played MISSING didn't work 8\ what's wrong?


I'm having similar issues. NOT play_count MISSING doesn't work for me. If I put it in, no files show up. I'm trying to make a Most Played albums list by using $avg, and I'm having trouble figuring out the script. I mostly copied the $avg rating script posted earlier, but it's not quite working.


I use "%play_counter% GREATER 0" for testing for play count, and I use "%last_played% HAS 20" for testing for a last played date. (Assumes all your last_played values are going to be in 2000's)...
Fitret
QUOTE(cwbowron @ Sep 6 2006, 08:48) *

QUOTE(Fitret @ Sep 5 2006, 21:13) *

QUOTE(Dr.Death @ Aug 15 2006, 00:07) *

Very usefull plugin, thx!
but NOT last_played MISSING didn't work 8\ what's wrong?


I'm having similar issues. NOT play_count MISSING doesn't work for me. If I put it in, no files show up. I'm trying to make a Most Played albums list by using $avg, and I'm having trouble figuring out the script. I mostly copied the $avg rating script posted earlier, but it's not quite working.


I use "%play_counter% GREATER 0" for testing for play count, and I use "%last_played% HAS 20" for testing for a last played date. (Assumes all your last_played values are going to be in 2000's)...


Okay, that did seem to work. Now, what I really want to achieve here is not the last 100 tracks I've played, but rather the last few albums (100 tracks of albums is fine) that I've played. It's MOSTLY working, but there are a few bugs. Screenshots would probably explain it best, so here they are...

IPB Image

I'm assuming the ordering issue is because I'm populating by play_count, but still, is there any way to fix that? I'm not so sure how to fix the non-full album issue. All of the albums that aren't full have been played through at least once, so all of their tracks have a play_count of at least 1. However, I'm also concerned in the future that what if I really don't like one particular track on an album, so it's play_count is zero for some reason, but the rest of the album has been heard 8,000 times. Can I use $avg('%play_count%') GREATER 0 as Criteria?
cwbowron
QUOTE(Fitret @ Sep 6 2006, 09:40) *

Okay, that did seem to work. Now, what I really want to achieve here is not the last 100 tracks I've played, but rather the last few albums (100 tracks of albums is fine) that I've played. It's MOSTLY working, but there are a few bugs. Screenshots would probably explain it best, so here they are...


If you want it to sort by the tracknumber after populating, check the "Sort by display name" box. I am assuming that tracks are missing because those tracks are not in the 100 most played tracks. You are limiting it to 100 tracks, based on the play count. Tracks that are not in the top 100 most played are being cut so you do not have full albums.

QUOTE

I'm assuming the ordering issue is because I'm populating by play_count, but still, is there any way to fix that? I'm not so sure how to fix the non-full album issue. All of the albums that aren't full have been played through at least once, so all of their tracks have a play_count of at least 1. However, I'm also concerned in the future that what if I really don't like one particular track on an album, so it's play_count is zero for some reason, but the rest of the album has been heard 8,000 times. Can I use $avg('%play_count%') GREATER 0 as Criteria?


No, you cannot use $avg inside of criteria. It applies ONLY to a FOLDER. At the time the criteria is being applied no folders exist. I dont know if there is a way to do exactly what you want.

Best I can think of is this:

CODE

Source: @database:
Criteria: %play_count% GREATER 0
Format: @quote<@format<$avg('%play_count%'>> %album%|%tracknumber% - %title%
Limit: 10 SUBFOLDERS
Population Order: $sub(99999,%play_counter%)
[x] Sort by display name after populating.


That should give you 10 albums that contain the most played songs.
Fitret
QUOTE(cwbowron @ Sep 6 2006, 09:59) *

QUOTE(Fitret @ Sep 6 2006, 09:40) *

Okay, that did seem to work. Now, what I really want to achieve here is not the last 100 tracks I've played, but rather the last few albums (100 tracks of albums is fine) that I've played. It's MOSTLY working, but there are a few bugs. Screenshots would probably explain it best, so here they are...


If you want it to sort by the tracknumber after populating, check the "Sort by display name" box. I am assuming that tracks are missing because those tracks are not in the 100 most played tracks. You are limiting it to 100 tracks, based on the play count. Tracks that are not in the top 100 most played are being cut so you do not have full albums.

QUOTE

I'm assuming the ordering issue is because I'm populating by play_count, but still, is there any way to fix that? I'm not so sure how to fix the non-full album issue. All of the albums that aren't full have been played through at least once, so all of their tracks have a play_count of at least 1. However, I'm also concerned in the future that what if I really don't like one particular track on an album, so it's play_count is zero for some reason, but the rest of the album has been heard 8,000 times. Can I use $avg('%play_count%') GREATER 0 as Criteria?


No, you cannot use $avg inside of criteria. It applies ONLY to a FOLDER. At the time the criteria is being applied no folders exist. I dont know if there is a way to do exactly what you want.

Best I can think of is this:

CODE

Source: @database:
Criteria: %play_count% GREATER 0
Format: @quote<@format<$avg('%play_count%'>> %album%|%tracknumber% - %title%
Limit: 10 SUBFOLDERS
Population Order: $sub(99999,%play_counter%)
[x] Sort by display name after populating.


That should give you 10 albums that contain the most played songs.


Ahh, I used the $sub() method back when this first came out, and that opertion used to take awhile. I'm so glad it's sped up now! Anyways, this seems to work almost perfectly. The only remaining problem is that since it's sorted by name, the folders go from like, 3 - > 12 (based least listened to on top) as opposed to 12 -> 3 (most listened to appears as first subfolder). If I uncheck reverse, then the list naturally populates with the reverse of $sub(99999,%play_counter%), which means the hold list is albums I've only heard once.

Also, what's the syntax for $hidetext? I want to hide the number of times an album has been played (I think, haven't decided yet). I tried $hidetext(@quote<...>) and @hidden<@quote<...>>, with no luck. Edit: Figured out $hidetext, but as expected, it screws up the ordering of my 20 most played albums (it makes them alphabetical). I'm guessing that there's no way around this? Still, this isn't a big issue - I'd much rather find a fix for the issue above.
q-stankovic
Hello Chris!

Now after you started continuing the development of PT let me mention three smaller bugs/issues concerning the autorefresh of @playlist/s queries (two of them i already reported weeks ago):

1. If a @playlists<> query with checked autorefreshed option is created the autorefresh is not checked for the @playlist<> children

2. When you remove a whole playlist "bla" (f.e. by context menu switcher/tab) the @playlist<bla> is not refreshed if this @playlist<bla> query doesn't belong to a @playlists<> query

3. Changing the position of a playlist (by drag&drop or by "move left/right") don't causes autorefresh of @playlists<> query. So the order of playlists isn't correct anymore in Pt ( can be achieved by no population sort order and no display sort)

That's it! wink.gif
fabiospark
CODE
$if($greater($strstr(%<performer>%,voice),0)
    ,$if($greater($strstr(%<performer>%,woman),0),woman,
     $if($greater($strstr(%<performer>%,group),0),group,man))
    ,nobody)|
$left(%<performer>%,$sub($strchr(%<performer>%,'('),4))|
%artist%|
%title%
(The indentation in the code box is just for better readibility.)

I'm trying to port this query from old 1.7.0b3 where all the now converted %<performer>% were written as #performer#.
My files are tagged like that:

performer = Abbey Lincoln (voice - woman), other performers.......
performer = Jimmy Rushing (voice - man), other performers....
performer = Manhattan Transfer (voice - group), other performers.....

When I created it and whenever I refresh it, I get a sort of freezing up and the task manager shows me FB is eating up the RAM but nothing else happens. I have to kill the service.

Where is the problem?
--------------------------------

Can you confirm that $meta(x,y) now starts with y=0 but previously started with y=1?

Can you also confirm that @limit<> is not working with multi values %<tag>% ?

Thanks.
fabiospark
Sometimes (haven't tested when) I'm getting this in the console:
"Playlist Tree exceeds selection action limit"


Weird behaviour.

I use a %performer% multi values tag with info like: Sarah Vaughan (voice - woman)
or Jimmy Rushing (voice - man) or Manhattan Transfer (voice - group) plus the other performers.

Now I'm trying to port this query:

CODE
$if($greater($strstr(#performer#,voice),0),
$if($greater($strstr(#performer#,woman),0),woman,
$if($greater($strstr(#performer#,group),0),group,man)),nobody)|
$left(#performer#,$sub($strchr(#performer#,'('),4))|%artist%|%title%


Of course I replaced all the #performer# with %<performer>%.

This is what happens:

FB 0.8.3 PlaylistTree 1.7.0b3: It works and refreshes in less than 3 seconds.

FB 0.9.3.1 PlaylistTree 2.2.3: when I click OK after writing the format string I get a CPU load of 100% and I don't know for how long it would last because I killed FB process after 6 mins of that load.

--------

Please, clear me a doubt:

1.7.0b3 @node<node name> went into the "Query" text box.

Am I right that in 2.2.3 I have to put it in the "Source" box to make it work? Shall I have to put a "1" in the "Criteria" box instead?



Thanks.
cwbowron
QUOTE(fabiospark @ Sep 16 2006, 09:04) *

Sometimes (haven't tested when) I'm getting this in the console:
"Playlist Tree exceeds selection action limit"


Weird behaviour.


No, its working as designed. There's an option where you set your selection actions on the "Mouse and Keyboard" playlist tree options called File Limit. If the node you select has more files than this, the selection action will not be performed. Its the help reduce lag when you select a really large node. You can set it to 0 I believe and it will never be used.

QUOTE

Now I'm trying to port this query:

CODE
$if($greater($strstr(#performer#,voice),0),
$if($greater($strstr(#performer#,woman),0),woman,
$if($greater($strstr(#performer#,group),0),group,man)),nobody)|
$left(#performer#,$sub($strchr(#performer#,'('),4))|%artist%|%title%



There's some issues with the %<tag>% stuff in version 2.x of playlist tree that make it not work well inside of complicated scripts. It's on my list of bugs to fix at some point.

fabiospark
Is @limit<> still alive?
If yes, with which syntax?

Thanks.

(Sorry to pester you with all these questions but i've just started to ported seriously...)



Mmmmm, yes, I can see it still is.
I was trying it wit a %<tag>% and I couldn't see it work.
With a standard %tag% it works.

After testing it a bit, I'm a bit puzzled about some results I'm getting from a limited query.

CODE
@limit<5>$if($greater(%date%,1999),20$substr(%date%,3,3)0s,
19$substr(%date%,3,3)0s)|@limit<1>%artist%|%date% - %title%

The population order is set to $rand()

I checked with this other query
CODE
$if($greater(%date%,1999),20$substr(%date%,3,3)0s,19$substr(%date%,3,3)0s)|%date%|%artist%|%title%

and I can see I have one track of 1917 and 177 of the 20s (from 13 different artists).
With the limited query, I would expect to always get the 1917 track in the 1910s group and to get 5 tracks from different artists for the 1929s group. Instead, after countless refreshings I've never seen appear a 1910s group and I always end up with a Fats Waller track as a single component of the 1920s group: would you mind explaying me how the @limit<> works, in detail?

Thanks.
fabiospark
If I hide both the lines and the root node the + disappears and I can't use the tree.

---------

It seems %__replaygain_track_gain% (even without the %%) is not considered in the criteria box.
It works in the format, instead.
Am I wrong or should I use some other formatting in the criteria box?


Thanks.
cwbowron
QUOTE(fabiospark @ Sep 16 2006, 17:22) *

If I hide both the lines and the root node the + disappears and I can't use the tree.


That's how the standard treeview control works.

In that situation, you can use the right and left arrow keys to expand and contract the node.
DarkFritz
Hi!

I'd really like to use this query artist IS @format<$playing('%artist%')> (copied it from the author's homepage). It works quite fine except the artist's name contains a ( or ), then the query returns just the entire database. When I change the query to artist IS "@format<$playing('%artist%')>" it works for artists with ( or ) in their names, but it doesn't work anymore for artists with quotation marks " in their names.

Does anybody know a solution for this problem?

Thank you
cwbowron
QUOTE(DarkFritz @ Sep 17 2006, 11:06) *
I'd really like to use this query artist IS @format<$playing('%artist%')> (copied it from the author's homepage). It works quite fine except the artist's name contains a ( or ), then the query returns just the entire database. When I change the query to artist IS "@format<$playing('%artist%')>" it works for artists with ( or ) in their names, but it doesn't work anymore for artists with quotation marks " in their names.


I can't try it right now, but you might be able to use:

CODE
artist IS "@format<$replace($playing('%artist%'),$char(34),'$char(34)')>"
DarkFritz
QUOTE(cwbowron @ Sep 17 2006, 10:00) *

QUOTE(DarkFritz @ Sep 17 2006, 11:06) *
I'd really like to use this query artist IS @format<$playing('%artist%')> (copied it from the author's homepage). It works quite fine except the artist's name contains a ( or ), then the query returns just the entire database. When I change the query to artist IS "@format<$playing('%artist%')>" it works for artists with ( or ) in their names, but it doesn't work anymore for artists with quotation marks " in their names.


I can't try it right now, but you might be able to use:

CODE
artist IS "@format<$replace($playing('%artist%'),$char(34),'$char(34)')>"



Nope, it works for ( and ), but artists with " aren't working

But nevertheless thank you for your great plugin
fabiospark
What @format and @quote do?

When should I use them?

Where can I use them?


Thanks.
dano
This is a query that I use in foobar 0.8.3 with the 1.7.13 version of this plugin to show the songs I've played today. What would this look like in the current version 2.2.3 for foobar 0.9.3 ?
Query:
CODE
$strcmp($replace($left(%last_played%,10),-,),%_systemdate%)
Kuwanger
Say, is there a way to exclude certain files, for example .m3u-files, in a @drop query?
cwbowron
QUOTE(Kuwanger @ Sep 24 2006, 16:06) *

Say, is there a way to exclude certain files, for example .m3u-files, in a @drop query?


no, but excluding playlists from @drop queries has been requested and is on the list... and I may get around to it sometime :-)
Kuwanger
Aha, i see.

Well, guess i have to do it manually then while we wait for that feature. =)
Superunknown
(error)
ciaran
Not sure what I'm doing wrong here sad.gif

CODE

$ifgreater($meta_num(%artist%),6,@format<'%<$meta(%artist%,1),$meta(%artist%,2),$meta(%artist%,3),$meta(%artist%,4),$meta(%artist%,5)>%'>,
$select($meta_num(%artist%),%<$meta(%artist%,0)>%'>,
@format<'%<$meta(%artist%,1)>%'>,
@format<'%<$meta(%artist%,1)>%,%<$meta(%artist%,2)>%'>,
@format<'%<$meta(%artist%,1)>%,%<$meta(%artist%,2)>%,%<$meta(%artist%,3)>%'>,
@format<'%<$meta(%artist%,1)>%,%<$meta(%artist%,2)>%,%<$meta(%artist%,3)>%,%<$meta(%artist%,4)>%'>,
@format<'%<$meta(%artist%,1)>%,%<$meta(%artist%,2)>%,%<$meta(%artist%,3)>%,%<$meta(%artist%,4)>%,%<$meta(%artist%,5)>%'>))
|%album%


What I am attempting to do:
* if # artists > 5 then add 1-5 to the list
* if # artists = 1 then add 0 to the list
* if # artists = 2 then add 1 to the list
* if # artists = 3 then add 1-2 to the list
* if # artists = 4 then add 1-3 to the list
* if # artists = 5 then add 1-4 to the list

Query comes out blank. Any I am probably getting the @format wrong. I have NO idea how @format and @quote works. Appreciate any clues.

Thx!
Mystiq
QUOTE(kockroach @ Jun 10 2006, 21:34) *

QUOTE(gob @ Jun 10 2006, 14:14) *

it could be something in your queries causing a crazy character to appear. post your pts file, i'll check it out.

Here is what is in my PTS file:
CODE

(FOLDER "Playlist Tree" 1 :CONTENTS (
(QUERY "Playlists" 0 "@playlists" nil "%artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 1 :CONTENTS (
(QUERY "*Browser*" 0 "@playlist<*Browser*>" nil "%artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
(QUERY "Default" 0 "@playlist<Default>" nil "%artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
))
(FOLDER "Music DB Stats" 1 :CONTENTS (
(QUERY "Total Artists: @format<$ifgreater(%_foldercount%,0,%_foldercount%,%_itemcount%)>" 0 "@database" "%__codec% IS FLAC" "%album artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
(QUERY "Total Albums: @format<$ifgreater(%_foldercount%,0,%_foldercount%,%_itemcount%)>" 0 "@database" "%__codec% IS FLAC AND tracknumber IS 1 OR tracknumber IS 01" "%album artist% - %album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
(QUERY "Total Tracks: @format<$ifgreater(%_foldercount%,0,%_foldercount%,%_itemcount%)>" 0 "@database" "%__codec% IS FLAC" "%title%" nil 0)
(QUERY "Total Genres: @format<$ifgreater(%_foldercount%,0,%_foldercount%,%_itemcount%)>" 0 "@database" "%__codec% IS FLAC" "%genre%|%album artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
)) (FOLDER "Database Views" 1 :CONTENTS (
(QUERY "True Directory View" 0 "@database" nil "$directory(%_path%,3)|$directory(%_path%,2)|$directory(%_path%,1)|$num(%tracknumber%,2). %title%" nil 0)
(QUERY "Artist by Alphabet" 0 "@database" "%__codec% IS FLAC" "$cut($if($strcmp($left(%album artist%,4),The ),$right(%album artist%,$sub($len(%album artist%),4))', 'The,%album artist%),1)|%artist%|%album%|$num(%tracknumber%,2). %title%" "$cut($if($strcmp($left(%artist%,4),The ),$right(%artist%,$sub($len(%artist%),4))', 'The,%artist%),1)|$if($strcmp($left(%artist%,4),The ),$right(%artist%,$sub($len(%artist%),4))', 'The,%artist%)|'('%date%')' %album%|$num(%tracknumber%,2). %title%" 0)
(QUERY "Artist by Genre" 0 "@database" "%__codec% IS FLAC" "%genre%|%album artist%|'('%date%')' %album%|$num(%tracknumber%,2). %title%" "%genre%|$if($strcmp($left(%album artist%,4),The ),$right(%album artist%,$sub($len(%album artist%),4))', 'The,%album artist%)|'('%date%')' %album%|$num(%tracknumber%,2). %title%" 0)
(QUERY "Artist - Album by Date" 0 "@database" "%__codec% IS FLAC" "%album artist%|'('%date%')' %album%|$num(%tracknumber%,2). %title%" "$if($strcmp($left(%album artist%,4),The ),$right(%album artist%,$sub($len(%album artist%),4))', 'The,%album artist%)|'('%date%')' %album%|$num(%tracknumber%,2). %title%" 0)
(QUERY "Album by Title" 0 "@database" "%__codec% IS FLAC" "$cut(%album%,1)|%album%|$num(%tracknumber%,2). %title%" nil 0)
(QUERY "Album by Year" 0 "@database" "%__codec% IS FLAC" "%date%|%album%|$num(%tracknumber%,2). %title%" nil 0)
(QUERY "Individual Tracks by Codec" 0 "@database" nil "$directory(%_path%,3) 'Singles' '(''@format<%_itemcount%>'')'|$cut(%title%,1)|%title%" nil 0)
)) (FOLDER "Dynamic Playlists" 1 :CONTENTS (
(QUERY "Random Album" 0 "@database" "%__codec% IS FLAC" "%album artist% - %album%|[$num(%tracknumber%,2) - ]%title%" "$rand()" 0 :MAX-FOLDERS 1)
(QUERY "Random Artist" 0 "@database" "%__codec% IS FLAC" "%album artist%|%album%|[$num(%tracknumber%,2) - ]%title%" "$rand()" 0 :MAX-FOLDERS 1)
(QUERY "Random Album by Genre" 0 "@database" "%__codec% IS FLAC" "@limit<1>%genre%|%album artist% - %album%|$num(%tracknumber%,2). %title%" "%genre%|$rand()" 0)
(QUERY "100 Random Singles" 0 "@database" "%__codec% IS FLAC" "%title%" "$rand()" 0 :MAX-TRACKS 100)
(QUERY "10 Random Singles by Genre" 0 "@database" "%__codec" "%album artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
(QUERY "Ska-Punk Singles -- @format<%_size_abb%>" 0 "@database" "genre IS punk rock AND %__codec% IS MP3 OR genre IS ska AND %__codec% IS MP3" "%artist% - %title%" "$rand()" 0 :MAX-SIZE 960)
(QUERY "MOD 588 Failed" 0 "@database" "NOT $mod(%_length_samples%,588) IS 0" "%__codec%|%album artist%|'('%date%')' %album%|$num(%tracknumber%,2). %title%" "$if($strcmp($left($if2(%album artist%,%artist%),4),The ),$right($if2(%album artist%,%artist%),$sub($len($if2(%album artist%,%artist%)),4))', 'The,$if2(%album artist%,%artist%))|'('%date%')' %album%|$num(%tracknumber%,2). %title%" 0)
(QUERY "MOD 588 Passed" 0 "@database" "$mod(%_length_samples%,588) IS 0" "%__codec%|%album artist%|'('%date%')' %album%|$num(%tracknumber%,2). %title%" "$if($strcmp($left($if2(%album artist%,%artist%),4),The ),$right($if2(%album artist%,%artist%),$sub($len($if2(%album artist%,%artist%)),4))', 'The,$if2(%album artist%,%artist%))|'('%date%')' %album%|$num(%tracknumber%,2). %title%" 0)
(QUERY "Never Played" 0 "@database" "%__codec% IS FLAC AND play_counter MISSING" "%artist% - %title%" "%artist%|%title%" 0)
(FOLDER "Top 50" 1 :CONTENTS (
(QUERY "Most Played" 0 "@database" "[%play_counter%]" "'('$num(%play_counter%,3)')' %artist% - %title%" "$num(%play_counter%,3)|%artist%|%title%" 0 :REVERSE t :MAX-TRACKS 50)
(QUERY "Last Played" 0 "@database" "[%last_played%]" "%artist% - %title%" "%last_played%|%artist%|%title%" 0 :REVERSE t :MAX-TRACKS 50)
(QUERY "Least Played" 0 "@database" "[%play_counter%]" "%artist% - %title%" "%play_counter%|%artist%|%title%" 0 :MAX-TRACKS 50)
))))))


The above display fine, but if I remove a panel, then put it back, the PTS file is changed to something like this:
CODE

(FOLDER "Playlist Tree" 1 :CONTENTS (
(QUERY "Playlists" 0 "@playlists" nil "%artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 1 :CONTENTS (
(QUERY "*Browser*" 0 "@playlist<*Browser*>" nil "%artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
(QUERY "Default" 0 "@playlist<Default>" nil "%artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
))
(FOLDER "Music DB Stats" 1 :CONTENTS (
(QUERY "Total Artists: @format<$ifgreater(%_foldercount%,0,%_foldercount%,%_itemcount%)>" 0 "@database" "%__codec% IS FLAC" "%album artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
(QUERY "Total Albums: @format<$ifgreater(%_foldercount%,0,%_foldercount%,%_itemcount%)>" 0 "@database" "%__codec% IS FLAC AND tracknumber IS 1 OR tracknumber IS 01" "%album artist% - %album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
(QUERY "Total Tracks: @format<$ifgreater(%_foldercount%,0,%_foldercount%,%_itemcount%)>" 0 "@database" "%__codec% IS FLAC" "%title%" nil 0)
(QUERY "Total Genres: @format<$ifgreater(%_foldercount%,0,%_foldercount%,%_itemcount%)>" 0 "@database" "%__codec% IS FLAC" "%genre%|%album artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
)) (FOLDER "Database Views" 1 :CONTENTS (
(QUERY "True Directory View" 0 "@database" nil "$directory(%_path%,3)|$directory(%_path%,2)|$directory(%_path%,1)|$num(%tracknumber%,2). %title%" nil 0)
(QUERY "Artist by Alphabet" 0 "@database" "%__codec% IS FLAC" "$cut($if($strcmp($left(%album artist%,4),The ),$right(%album artist%,$sub($len(%album artist%),4))', 'The,%album artist%),1)|%artist%|%album%|$num(%tracknumber%,2). %title%" "$cut($if($strcmp($left(%artist%,4),The ),$right(%artist%,$sub($len(%artist%),4))', 'The,%artist%),1)|$if($strcmp($left(%artist%,4),The ),$right(%artist%,$sub($len(%artist%),4))', 'The,%artist%)|'('%date%')' %album%|$num(%tracknumber%,2). %title%" 0)
(QUERY "Artist by Genre" 0 "@database" "%__codec% IS FLAC" "%genre%|%album artist%|'('%date%')' %album%|$num(%tracknumber%,2). %title%" "%genre%|$if($strcmp($left(%album artist%,4),The ),$right(%album artist%,$sub($len(%album artist%),4))', 'The,%album artist%)|'('%date%')' %album%|$num(%tracknumber%,2). %title%" 0)
(QUERY "Artist - Album by Date" 0 "@database" "%__codec% IS FLAC" "%album artist%|'('%date%')' %album%|$num(%tracknumber%,2). %title%" "$if($strcmp($left(%album artist%,4),The ),$right(%album artist%,$sub($len(%album artist%),4))', 'The,%album artist%)|'('%date%')' %album%|$num(%tracknumber%,2). %title%" 0)
(QUERY "Album by Title" 0 "@database" "%__codec% IS FLAC" "$cut(%album%,1)|%album%|$num(%tracknumber%,2). %title%" nil 0)
(QUERY "Album by Year" 0 "@database" "%__codec% IS FLAC" "%date%|%album%|$num(%tracknumber%,2). %title%" nil 0)
(QUERY "Individual Tracks by Codec" 0 "@database" nil "$directory(%_path%,3) 'Singles' '(''@format<%_itemcount%>'')'|$cut(%title%,1)|%title%" nil 0)
)) (FOLDER "Dynamic Playlists" 1 :CONTENTS (
(QUERY "Random Album" 0 "@database" "%__codec% IS FLAC" "%album artist% - %album%|[$num(%tracknumber%,2) - ]%title%" "$rand()" 0 :MAX-FOLDERS 1)
(QUERY "Random Artist" 0 "@database" "%__codec% IS FLAC" "%album artist%|%album%|[$num(%tracknumber%,2) - ]%title%" "$rand()" 0 :MAX-FOLDERS 1)
(QUERY "Random Album by Genre" 0 "@database" "%__codec% IS FLAC" "@limit<1>%genre%|%album artist% - %album%|$num(%tracknumber%,2). %title%" "%genre%|$rand()" 0)
(QUERY "100 Random Singles" 0 "@database" "%__codec% IS FLAC" "%title%" "$rand()" 0 :MAX-TRACKS 100)
(QUERY "10 Random Singles by Genre" 0 "@database" "%__codec" "%album artist%|%album%|[$num(%tracknumber%,2) - ]%title%" nil 0)
(QUERY "Ska-Punk Singles -- @format<%_size_abb%>" 0 "@database" "genre IS punk rock AND %__codec% IS MP3 OR genre IS ska AND %__codec% IS MP3" "%artist% - %title%" "$rand()" 0 :MAX-SIZE 960)
(QUERY "MOD 588 Failed" 0 "@database" "NOT $mod(%_length_samples%,588) IS 0" "%__codec%|%album artist%|'('%date%')' %album%|$num(%tracknumber%,2). %title%" "$if($strcmp($left($if2(%album artist%,%artist%),4),The ),$right($if2(%album artist%,%" 0)
))))sub($len($if2(%album artist%,%artist%)),4))', 'The,$if2(%album artist%,%artist%))|'('%date%')' %album%|$num(%tracknumber%,2). %title%" 0)
(QUERY "MOD 588 Passed" 0 "@database" "$mod(%_length_samples%,588) IS 0" "%__codec%|%album artist%|'('%date%')' %album%|$num(%tracknumber%,2). %title%" "$if($strcmp($left($if2(%album artist%,%artist%),4),The ),$right($if2(%album artist%,%artist%),$sub($len($if2(%album artist%,%artist%)),4))', 'The,$if2(%album artist%,%artist%))|'('%date%')' %album%|$num(%tracknumber%,2). %title%" 0)
(QUERY "Never Played" 0 "@database" "%__codec% IS FLAC AND play_counter MISSING" "%artist% - %title%" "%artist%|%title%" 0)
(FOLDER "Top 50" 1 :CONTENTS (
(QUERY "Most Played" 0 "@database" "[%play_counter%]" "'('$num(%play_counter%,3)')' %artist% - %title%" "$num(%play_counter%,3)|%artist%|%title%" 0 :REVERSE t :MAX-TRACKS 50)
(QUERY "Last Played" 0 "@database" "[%last_played%]" "%artist% - %title%" "%last_played%|%artist%|%title%" 0 :REVERSE t :MAX-TRACKS 50)
(QUERY "Least Played" 0 "@database" "[%play_counter%]" "%artist% - %title%" "%play_counter%|%artist%|%title%" 0 :MAX-TRACKS 50)
))))))


I thought that perhaps it might be due to a folder within a folder. Even if I bring that last folder ("Top 50") into the main "Dynamic Playlist" folder, it still happens.


Thanks for posting that code, helps a lot noobs like me. Im requesting if theres any more people who could post their configs, id really appreciate it.

Thanks again and also greets to the PT author, brilliant plugin. smile.gif
wolfsong
Is there a list of working examples/favorites somewhere? I looked at the bowron forum but the link there is broken. It would be great to have a thread with screenshots and code to look at instead of asking for things that have already been posted or recreating the wheel. Maybe they could be added to the bowron wiki examples (but with code for copy and paste)???

Specifically, I'm looking for a way to handle fields with multiple values (using the \ seperator) and the Special lists shown here.

IPB Image
wolfsong
QUOTE(wolfsong @ Oct 14 2006, 17:06) *

Is there a list of working examples/favorites somewhere? I looked at the bowron forum but the link there is broken. It would be great to have a thread with screenshots and code to look at instead of asking for things that have already been posted or recreating the wheel. Maybe they could be added to the bowron wiki examples (but with code for copy and paste)???

Specifically, I'm looking for a way to handle fields with multiple values (using the \ seperator) and the Special lists shown here.

IPB Image

Anyone?
metal_termite
Is this examples of queries page what you're asking for?
wolfsong
QUOTE(metal_termite @ Oct 18 2006, 17:29) *

Is this examples of queries page what you're asking for?

Unfortunately not. While that page does give some examples, there are not enough to clue me in on how to create the ones from the screenshot such as 100 Top Rated, 100 Most Played and 100 Last Played.

I'm also looking for what ideas others may have already come up. Thanks.
gob
is there a way to exclude directories, or even only include certain directories in queries?

also.. if i wanted to create a style query, files will fall under multiple styles. is it possible to include them under more than one branch of the tree?
Fractal_Mortality
I wasn't sure which thread to put this question in, so I'll throw it in this one since it's been more recently discussed:

Is there a way to make foo_browser sort according to playlist tree's query sorting parameters?
azazel100
I'm not sure if this was mentioned before..

when starting foobar it seams that display text functions don't get evaluated or @hidden2 is disregarded.

my config:

CODE
@quote<@format<$ifgreater(5,%_itemcount%,@hidden2 ,)>>
$replace(%album artist%,'The ',)|
[#'<'%album type%'>'|]
$if(%track%,['['%date%']']$if2(%album%,'<unknown>'),'<incomplete>')|
[%discnumber%.][$num(%tracknumber%,2).]
[%track artist% - ]%title%
$if(%track%,, ['['%album%']'])


first line alows me to filter out artist with less then 5 song, but doesn't work at startup...

great plugin btw ;]
odyssey
I'm currently using playback weighted on rating. I'd like to put this function on playlist_tree, to have static playlists, with many tracks rated 5 stars, and less tracks rated 2 stars. Is this even possible? I could not get the following query to limit "some" tracks - instead it just takes any track in the database:

Edit, it should be in quotes:

CODE
rating GREATER "$add($mod($rand(),4),2)"


A have a few feature requests:
* Option to disable child objects (tracks) in querys
* Option to expand collapse folders when they are left-clicked? (...or maybe i'm just missing something here huh.gif)
gob
think it would be a good idea to share some of these .pts files in a separate thread? if so, feel free to split this and i can edit some rules. i'm sure there's a lot of creative queries out there.

Additional components some of these scripts need:
foo_cwb_hooks.dll
foo_playcount.dll (official)


Top 250 Songs
here's one i just put together to generate a favorite list of tracks sorted by the rating and the average time between playing. as long as it has played at least 10 times, the rating is greater than 3, and it hasn't played in the last 7 days.
CODE
(QUERY "@rgb<252,252,252>Weekly Top 250@refresh " 0 "@database" "rating GREATER 3 AND (""$cwb_datediff(%last_played%,%cwb_systemdate%)"" GREATER 7 AND %play_count% GREATER 5)" "%title% - %artist%" "$num(%rating%,2)$sub(10000000000,$num($div($mul($cwb_datediff(%first_played%,%cwb_systemdatetime%),1000000),%play_count%),10))" 0 :REVERSE t :MAX-TRACKS 250)


by Albums
depending on the tags, this lists all of the music in the database by:
"artist \ album \ title" or "artist \ title" or "various albums\ album \ title"
CODE
(QUERY "@rgb<252,252,252>All Music [@format<$cwb_splitnum(%_itemcount%,',') tracks>]" 0 "@database" nil "$if($and(%artist%,$meta(title)),$if(%various%,Various Artists,$if($strcmp($left(%artist%,4),The ),$right(%artist%,$sub($len(%artist%),4))', 'The,%artist%))|$if2(%album%[ '('%date%')'],'@rgb<128,128,128>'●  singles  ●)|$if(%discname%,%discname%|)$meta(title),'@rgb<128,128,128>''('tags missing')'|$replace(%path%,\,|))" "$if($and(%artist%,%title%),1$if(%various%,'(((',$replace(%artist%,The ,))|$if($not(%various%),%date%)%album%|%discnumber%%tracknumber%%title%,0|%path_sort%)" 0)


by Genre
this separates the tracks by genre. then lists them as a similar method as above except the various artists are no longer displayed as albums, but singles underneath each artist.
CODE
(QUERY "@rgb<252,252,252>by Genre" 1 "@database" "NOT genre MISSING AND NOT @format<'$meta(title)'> MISSING AND NOT artist MISSING" "%<genre>% '('@format<'$cwb_splitnum(%_itemcount%,',')'> tracks')'|$if($strcmp($left(%artist%,4),The ),$right(%artist%,$sub($len(%artist%),4))', 'The,%artist%)|$if($and(%album%,$not(%various%)),%album% '('%date%')','@rgb<128,128,128>'●  singles  ●)|$if(%discname%,%discname%|)%title%" "%genre%|$replace(%artist%,The ,)|$if($and(%album%,$not(%various%)),%date%%album%,%various%)|%discnumber%%tracknumber%%title%" 0)


by Rating
this displays tracks displayed as rating \ artist \ title
CODE
(QUERY "@rgb<252,252,252>by Rating" 1 "@database" "rating GREATER 0 AND NOT artist MISSING AND NOT title MISSING" "@rgb<2%rating%%rating%,1$add(2,%rating%)$add(4,%rating%),0>$repeat(♫ ,%rating%)|$if2(%genre%,'@rgb<128,128,128>'unknown genre)|$if($strcmp($left(%artist%,4),The ),$right(%artist%,$sub($len(%artist%),4))', 'The,%artist%)|%title%" "$sub(10,%rating%)| %genre% | $replace(%artist%,The ,) | %title%" 0)


by Codec
this separates the files by codec.if the tracks are lossy, then by codec \ bitrates \artist - album \ title
CODE
(QUERY "@rgb<252,252,252>Codec" 0 "@database" "NOT album MISSING" "$if(%__bitspersample%,,'@rgb<128,128,128>')%codec%|$if(%__bitspersample%,,$ifgreater(%__bitrate%,319,$puts(brgroup,320+ kbps),$ifgreater(%__bitrate%,255,$puts(brgroup,256-319 kbps),$ifgreater(%__bitrate%,191,$puts(brgroup,192-255 kbps),$ifgreater(%__bitrate%,127,$puts(brgroup,128-191 kbps),$puts(brgroup,  0-127 kbps)))))$get(brgroup)|)$if(%various%,%album%,%artist% - %album%)|%title%" "$if(%__bitspersample%,0,1)%codec%|$if(%__bitspersample%,,%__bitrate%|)$if(%various%,%album%,%artist% - %album%)|%discnumber%%tracknumber%" 0)


by Age
this query divides tracks by decade unless the album has this or last years date, if so this years and last years will be separated.
CODE
(QUERY "@rgb<252,252,252>Age" 0 "@database" "NOT album MISSING AND NOT artist MISSING AND NOT date MISSING AND NOT title MISSING AND NOT tracknumber MISSING AND various MISSING" "$if($stricmp($left(%cwb_systemdate%,4),%date%),This year''s,$if($stricmp($left(%cwb_systemdate%,4),$add(%date%,1)),Last year''s,$left(%date%,3)0''s))|%genre%|%artist%|%album%|%title%" "$if($stricmp($left(%cwb_systemdate%,4),%date%),0,$if($stricmp($left(%cwb_systemdate%,4),$add(%date%,1)),1,$sub(999,$left(%date%,3))))|%genre%|%artist%|%album%|%discnumber%%tracknumber%" 0)


Playing: album
here are a few more i made that are in reference to the currently playing track.
this one shows the tracks in the currently playing album
CODE
(QUERY "@rgb<252,64,50>Now playing: @format<$playing('[%artist%]')>@refresh " 1 "@database" "album IS @format<$playing('%album%')> AND artist IS @format<$playing('%artist%')> OR album IS @format<$playing('%album%')> AND various IS 1" "$if($stricmp(%album%,%artist%),'['self titled album']',%album%)|%title%" "%discnumber%%tracknumber%" 0)


Playing: more by this artist
this shows all the albums and singles by this artist
CODE
(QUERY "@rgb<255,255,255>@format<More $cwb_removethe($playing('%artist%'))>@refresh " 1 "@database" "artist IS @format<$playing('%artist%')> AND NOT album IS @format<$playing('%album%')>" "$if($and(%album%,$not(%various%)),%album%,'@rgb<128,128,128>'●  singles  ●)|%title%" "$if($or(%various%,$not(%album%)),0|$if2(%title%,%filename_ext%),[%date%]%album%|$if(%title,[%discnumber%][%tracknumber%]%title%,%filename_ext%))" 0)


Playing: favorite tracks by this artist
this one shows the favorite tracks based on the rating, and the number of days between plays
CODE
(QUERY "@rgb<255,255,255>@format<Favorite $cwb_removethe($playing('%artist%')) Songs>@refresh " 0 "@database" "artist IS @format<$playing('%artist%')> AND rating GREATER 3" "%title%" "$num(%rating%,2)$sub(10000000000,$num($div($mul($cwb_datediff(%first_played%,%cwb_systemdatetime%),1000000),%play_count%),10))" 0 :REVERSE t :MAX-TRACKS 15)


i hope someone finds these useful, if not, i just made an elaborate backup of my settings tongue.gif
gob
%_play_length% stops at 23 days. is there any way to show weeks as well?
keanej6
The problem is with my playlist and i believe it to be the tagging of a few albums. Most of my albums display fine, but there is a small handful that comes up as <missing> under my browser. that specific album won't get categorized under the appropriate band, and the only information available are the song titles....when i go to customize it, foobar pops up the message that that specific object is not found. here's a pic of what i see...
IPB Image

Now i can temporarily fix this problem, by removing that playlist and readding it. then that <missing> disappears and the albums are organized just how i want them.
IPB Image

but when i add a mod to foobar or more importantly when i restart my computer, the same thing happens and the fixed albums go back to their misplaced sections under <missing>. Now i'm not very computer savvy, so this may be a simple problem... but if anybody can help me out, i'd really appreciate it. thank you!
gob
have you enabled "force preferred tag writing schemes on all files" and selected ID3v2+ID3v1 in the advanced options?
also try refreshing your database..

you may get more answers of you post this in the support forum
cwbowron
QUOTE
= Release 2.2.4 =
* Added "Clear Query Results" menu items
* Added notification callback so other plugins can be notified of tree selections.
* added global title formatting for treenode info: $treenode(arg) function. Possible arguments:
** name
** displayname
** size
** duration
** itemcount
** foldercount
** overallindex
** isleaf
** isfolder
** isquery
* auto refresh in a main thread callback
* put system icons at the end of the list so when they change it doesnt mess everything up
* set the background color in the icon selection box to the same color as your tree, so its easier to tell what will look good
gob
refresh doesn't quite work anymore. manually refreshing the trees, even after a file updates, it instantly looks like it was done (hoping you found a way to make big trees load faster since mine take 8 seconds to refresh rolleyes.gif) but then i noticed the tree didn't update. i had to open some nodes and then the refresh worked as before. also what does $treenode(arg) do? where can i use it?

is it possible to change the color midway thru a tree item? i tried this:
@rgb<202,202,202>%<genre>% @rgb<128,128,128>'('@format<'$cwb_splitnum(%_itemcount%,',')'> tracks')'|

also that $cwb_splitnum() function didnt work in that statement, but it does work in the label
cwbowron
QUOTE(gob @ Nov 18 2006, 02:13) *
also what does $treenode(arg) do? where can i use it?


It returns information about the currently selected treenode. I use inside a trackinfo panel that shows only information about the tree node ($treenode(displayname), $treenode(duration), etc)

QUOTE
is it possible to change the color midway thru a tree item? i tried this:


No. The @rgb refers to the entire line.
wolfsong
QUOTE(gob @ Nov 14 2006, 18:47) *

think it would be a good idea to share some of these .pts files in a separate thread? if so, feel free to split this and i can edit some rules. i'm sure there's a lot of creative queries out there.

That would be great!
QUOTE(gob @ Nov 14 2006, 18:47) *

i hope someone finds these useful, if not, i just made an elaborate backup of my settings tongue.gif

I certainly did. Especially since the link to the examples in the forum is broken, the examples in the wiki are few and can't be copied and the tutorial is out of date. Thanks.

EDIT: I saved a couple of your queries to a pts and loaded them but they didn't work.

I'd still like to know how to get 100 Most Played and 100 Last Played.

How do I modify the following to handle multiple artist values?

CODE
(QUERY "Now Playing: @format<$playing('%artist%')>@refresh " 1 "@database" "artist IS @format<$playing('%artist%')>" "@quote<@format<$if($greater(%_foldercount%,8),@hidden ,)>>%album%[ $char(40)%subtitle%$char(41)][ $char(91)%edition%$char(93)]|[$char(91)$num(%tracknumber%,2)$char(93) ]%title%[ $char(40)%version%$char(41)]" nil 1)

I tried setting the label to:
CODE
Now Playing: @format<$playing('%<artist>%')>

but all i get is a question mark. In other queries I've used %<artist>% in the format field which works perfectly.
q-stankovic
I don't know if it is due to the newest release: I configured a new layout and deided that it is the best for my workflow to apply the command "Send to library playlist" by ENTER. But it doesn't work! (It works with Space).

It was a nice improvement a few versions ago to turn off the automatical redraw of the at refresh to avoid the annoying flicker of the panel. However there are two situations where an automatic redraw would be useful:

1. Loading a child inside a panel seems to have no effect. It took me some time to recognize that i have to redraw tree manually.

2. Changing the name format for folders inside preferences also requires a manual refresh
gob
QUOTE(wolfsong @ Nov 18 2006, 12:03) *

EDIT: I saved a couple of your queries to a pts and loaded them but they didn't work.

I'd still like to know how to get 100 Most Played and 100 Last Played.

How do I modify the following to handle multiple artist values?

CODE
(QUERY "Now Playing: @format<$playing('%artist%')>@refresh " 1 "@database" "artist IS @format<$playing('%artist%')>" "@quote<@format<$if($greater(%_foldercount%,8),@hidden ,)>>%album%[ $char(40)%subtitle%$char(41)][ $char(91)%edition%$char(93)]|[$char(91)$num(%tracknumber%,2)$char(93) ]%title%[ $char(40)%version%$char(41)]" nil 1)

I tried setting the label to:
CODE
Now Playing: @format<$playing('%<artist>%')>

but all i get is a question mark. In other queries I've used %<artist>% in the format field which works perfectly.


if there were any problems with the queries they are fixed now since i edited that post. your problem might be because you don't have foo_playcount.dll (official) or foo_cwbhooks.dll

edit:
sorry, i don't know about multiple artist fields. i don't think it would work with the now playing queries..
wolfsong
QUOTE(gob @ Nov 20 2006, 00:22) *

if there were any problems with the queries they are fixed now since i edited that post. your problem might be because you don't have foo_playcount.dll (official) or foo_cwbhooks.dll

Thanks for the update; working now. It would be cool if the Weekly 250 displayed the playcount as well.
QUOTE(gob @ Nov 20 2006, 00:22) *
edit:
sorry, i don't know about multiple artist fields. i don't think it would work with the now playing queries..

Hopefully cwbowron can help with that one. I think it's his. Also, the Now Playing Query doesn't seem to work properly for albums by the artist. They are displayed but the tracks are not; works fine with tracks from VA releases.
cwbowron
QUOTE(wolfsong @ Nov 18 2006, 13:03) *

How do I modify the following to handle multiple artist values?

CODE
(QUERY "Now Playing: @format<$playing('%artist%')>@refresh " 1 "@database" "artist IS @format<$playing('%artist%')>" "@quote<@format<$if($greater(%_foldercount%,8),@hidden ,)>>%album%[ $char(40)%subtitle%$char(41)][ $char(91)%edition%$char(93)]|[$char(91)$num(%tracknumber%,2)$char(93) ]%title%[ $char(40)%version%$char(41)]" nil 1)



I dont think there is currently a way to do this. The %<tag>% format has limitations and this is outside those limitations.
gob
still cant figure out how the nested queries work. i made a nested query that looks like this:
CODE
@query<@rgb<255,255,255>@format<Favorite $cwb_removethe($playing('%artist%')) Songs>@refresh;@database;artist IS @format<$playing('%artist%')> AND rating GREATER 3" "%title%" "$num(%rating%,2)$sub(10000000000,$num($div($mul($cwb_datediff(%first_played%,%cwb_systemdatetime%),1000000),%play_count%),10))" 0 :REVERSE t :MAX-TRACKS 15);%title%>


but i dont know what do do with it. id like to put it under the existing query that i have that makes a tree of the currently playing album
fabiospark
Trying to port this query:

CODE
#album artist#|[& $if($stricmp(#album artist#,$meta(album artist,2)),$meta(album artist,1),$meta(album artist,2))]|[& $if($stricmp(#album artist#,$meta(album artist,3)),$meta(album artist,1),$meta(album artist,3))]|#album#|$num(%tracknumber%,2). %title%[ - %date%]


This is the translation:

CODE
%<album artist>%|[& $if($stricmp(%<album artist>%,$meta(album artist,1)),$meta(album artist,0),$meta(album artist,1))]|
[& $if($stricmp(%<album artist>%,$meta(album artist,2)),$meta(album artist,0),$meta(album artist,2))]|
%<album>%|$num(%tracknumber%,2). %title%[ - %date%]


this it the two outputs I'm getting: left=old right=new:

IPB Image


Does $meta(x,y) works zero based instead of 1 based as before?
Is there a way to get single values for tracks instead of doubles, at least?
Is there a way to get rid of that incorrect "& Ben Webster" branch?

Thanks.
fabiospark
What should I write in the criteria box to make a comparison work?

This is what I have in my 0.8 foobar.

CODE
$len(%tag%) GREATER 4


In spite of my attempts I couldn't find a way to see it work in 0.9 (PLT 2.2.3).

Thanks.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.