• Welcome to RadioDJ - Free Radio Automation Software Forum. Please log in or sign up.

Adding sweepers to MyAQL query rotation

Started by chrismadog, February 07, 2020, 10:48:37 AM

chrismadog

Hi everyone,

I have rotations which are MySQL queries such as:

SELECT `ID`, `artist`,`title` FROM `songs`
WHERE title LIKE '%*%'
AND artist LIKE '%2012%'
AND enabled = '1'
AND $ForceRepeatRules$
ORDER  BY RAND ()
LIMIT 50

How do I use $SweeperOnIntro$ (or alternative query) so it applies to every second or third track ?
Using $SweeperOnIntro$ in the MyQLD query results in it for every track which we do not want.

Using Track from category, I can select Swepers to only apply to every 2nd or third or Nth track as I desire but how to do it with MySQL queries ?

Thanks :)

Chris
Presenter - 4SDB - Rose City FM 89.3 - Warwick, QLD Australia.
Station Engineer - http://rosecityfm.org.au
Community Radio - Bringing you the best of local radio.

Marius

Hey Chris, sorry but it can't do what you need. When you are using MySQL queries, the results are manipulated and returned by MySQL server, so RadioDJ has very little control over them.
DOWNLOADS PAGE

HOW TO FIX RADIODJ DATABASE
----------------
Please don't PM me for support requests. Use the forums instead.

chrismadog

Thanks Marius.

What if I do a MySQL query with say one or two results without a sweeper and have a second one with a Sweeper ?
Will that work ?

Thanks for all your fantastic work. I love this program.

Regards,
Chris
Presenter - 4SDB - Rose City FM 89.3 - Warwick, QLD Australia.
Station Engineer - http://rosecityfm.org.au
Community Radio - Bringing you the best of local radio.

stevewa

You could try taking the result set from the first sql query, and in MySQL code, loop thru the result, if the track has a sweeper only put it into a second results data set if the previous 2 tracks did not have sweepers. It would require some advanced sql.

You might try making an alt category for songs with sweepers, and pull 50 from the reg cat and 50 from the songs with sweepers category, and then lol p thru inside sql and put them into a data set in the order you want (sweep, no, no, repeat) and then return that data set to rdj

There is always a way to fit a square peg into a round hole, either by carving ng the square, or enlarging the hole, lol