IPB

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
Problem With Recently Added
db78
post Apr 22 2007, 14:54
Post #1





Group: Members
Posts: 141
Joined: 14-March 07
Member No.: 41458



I made a playlist of recently added songs based on what people told me in this thread. It works almost perfectly. It does list all the recently added music, but the playlist is out of order. For example I add an Aerosmith CD to my playlist by using the file operations. When I go into the recently added playlist, all tracks aren't listed under the same entry, it's scattered around.



I want it so all the songs under the same album are listed under the same album in order of tracknumber, and not scattered around.

query
QUOTE
%date added% HAS "-" AND "$cwb_datediff(%date added%,%cwb_systemdate%)" LESS 4


sort
QUOTE
$sub(99999999999999,$replace(%last_played%,'-',,':',,' ',))


thanks!
Go to the top of the page
+Quote Post
kanak
post Apr 22 2007, 18:13
Post #2





Group: Members
Posts: 1190
Joined: 12-January 06
From: Cambridge, MA
Member No.: 27052



Your problem is that you're sorting by last_played instead of date added.

If you want it to be chronological, i'd suggest:
CODE
$sub(99999999999999,$replace(%date added%,'-',,':',,' ',))

Note: For a better measure, you might want to crop the date added so that it drops the "seconds" part of the value (e.g. just 2007-01-10 03:21 instead of 2007-01-10 03:21:20). Then ALSO sort by artist and album:
CODE
$sub(999999999999,$replace($left(%date added%,$sub($len(%date added%),2)),'-',,':',,' ',)),%artist%,%album%


This post has been edited by kanak: Apr 22 2007, 18:13
Go to the top of the page
+Quote Post
db78
post Apr 22 2007, 21:44
Post #3





Group: Members
Posts: 141
Joined: 14-March 07
Member No.: 41458



QUOTE (kanak @ Apr 22 2007, 10:13) *
Your problem is that you're sorting by last_played instead of date added.

If you want it to be chronological, i'd suggest:
CODE
$sub(99999999999999,$replace(%date added%,'-',,':',,' ',))

Note: For a better measure, you might want to crop the date added so that it drops the "seconds" part of the value (e.g. just 2007-01-10 03:21 instead of 2007-01-10 03:21:20). Then ALSO sort by artist and album:
CODE
$sub(999999999999,$replace($left(%date added%,$sub($len(%date added%),2)),'-',,':',,' ',)),%artist%,%album%


I tried using the second code. Now it's sorted by alphabetical order and not chronological, but at least the tracks are together now.
Go to the top of the page
+Quote Post
buktore
post Apr 23 2007, 03:46
Post #4





Group: Members
Posts: 506
Joined: 24-November 06
Member No.: 38011



the first code should do the trick if you add the whole album at the same time.

try this. newly added should be at the top.

QUOTE
$sub(999999999999,$replace($left(%date added%,$sub($len(%date added%),2)),'-',,':',,' ',))


and thanks to kanak. dropping the seconds part seem to make my autoplaylist update faster. smile.gif

This post has been edited by buktore: Apr 23 2007, 03:51
Go to the top of the page
+Quote Post
db78
post May 4 2007, 02:54
Post #5





Group: Members
Posts: 141
Joined: 14-March 07
Member No.: 41458



QUOTE (buktore @ Apr 22 2007, 19:46) *
the first code should do the trick if you add the whole album at the same time.

try this. newly added should be at the top.

QUOTE
$sub(999999999999,$replace($left(%date added%,$sub($len(%date added%),2)),'-',,':',,' ',))


and thanks to kanak. dropping the seconds part seem to make my autoplaylist update faster. smile.gif


Sweet I got it to organize by album, the only problem now is that the newly added albums are at the bottom of the playlist, is there a way to make it at the top? Also under each album, the tracks aren't in order. I'm guessing foobar doesn't add the tracks in order, but is there a way to have them sorted in order within each album?

This post has been edited by db78: May 4 2007, 02:59
Go to the top of the page
+Quote Post
kanak
post May 4 2007, 02:59
Post #6





Group: Members
Posts: 1190
Joined: 12-January 06
From: Cambridge, MA
Member No.: 27052



QUOTE (db78 @ May 3 2007, 21:54) *
QUOTE (buktore @ Apr 22 2007, 19:46) *

the first code should do the trick if you add the whole album at the same time.

try this. newly added should be at the top.

QUOTE
$sub(999999999999,$replace($left(%date added%,$sub($len(%date added%),2)),'-',,':',,' ',))


and thanks to kanak. dropping the seconds part seem to make my autoplaylist update faster. smile.gif


Sweet I got it to organize by album, the only problem now is that the newly added albums are at the bottom of the playlist, is there a way to make it at the top?


That's strange. The $sub thing should make the latest added files appear at the top. Could you post your sort string? Also, try refreshing the playlist.
Go to the top of the page
+Quote Post
db78
post May 4 2007, 03:58
Post #7





Group: Members
Posts: 141
Joined: 14-March 07
Member No.: 41458



QUOTE (kanak @ May 3 2007, 18:59) *
QUOTE (db78 @ May 3 2007, 21:54) *

QUOTE (buktore @ Apr 22 2007, 19:46) *

the first code should do the trick if you add the whole album at the same time.

try this. newly added should be at the top.

QUOTE
$sub(999999999999,$replace($left(%date added%,$sub($len(%date added%),2)),'-',,':',,' ',))


and thanks to kanak. dropping the seconds part seem to make my autoplaylist update faster. smile.gif


Sweet I got it to organize by album, the only problem now is that the newly added albums are at the bottom of the playlist, is there a way to make it at the top?


That's strange. The $sub thing should make the latest added files appear at the top. Could you post your sort string? Also, try refreshing the playlist.


Query:
CODE
%date added% HAS "-" AND "$cwb_datediff(%date added%,%cwb_systemdate%)" LESS 4


Sort:
CODE
$sub(999999999999,$replace($left(%date added%,$sub($len(%date added%),2)),'-',,':',,' ',))
Go to the top of the page
+Quote Post
kanak
post May 4 2007, 05:06
Post #8





Group: Members
Posts: 1190
Joined: 12-January 06
From: Cambridge, MA
Member No.: 27052



I think i found the culprit: it's not the sort code but your autoplaylist query. If your date added is of the form YYYY-MM-DD HH:MM:SS, you should find the difference with %cwb_systemdatetime% (NOT %cwb_systemdate)

so, the autoplaylist code should now be:

CODE
%date added% HAS "-" AND "$cwb_datediff(%date added%,%cwb_systemdatetime%)" LESS 4


i also re-wrote the sort code (should be more efficient):


CODE
$sub(999999999999,$replace($left(%date added%,$sub($len(%date added%),3)),'-',,':',,' ',)),%album artist%,%album%


(I'm assuming your Date added format is: YYYY-MM-DD HH:MM:SS . What i've done is to strip the :SS part, then remove the dashes, the colons and the space, and subtract it from a large number to get it to sort by latest added. Then it sorts by album artist and the album.)

This post has been edited by kanak: May 4 2007, 05:07
Go to the top of the page
+Quote Post
db78
post May 4 2007, 07:01
Post #9





Group: Members
Posts: 141
Joined: 14-March 07
Member No.: 41458



Yes!! Oh good lord thank you so much. It's been bugging me for so long. I also changed my custom sort to systemdatetime, and it's working perfectly now. Thank you so much!
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 1st October 2014 - 14:18