FYI my newer PALs keep a running list of shows and use a toggle to represent which show is currently active rather than keeping only one record in the table.
Table statement:
Code:
CREATE TABLE IF NOT EXISTS fhr_show_info (
id INTEGER UNSIGNED NOT NULL,
title TEXT NOT NULL,
description TEXT NOT NULL,
forum_id INTEGER UNSIGNED NOT NULL default 0,
active INTEGER UNSIGNED NOT NULL default 0,
PRIMARY KEY ( id ) )
ENGINE = MyISAM;
Then I use a view on the table to return the current show:
Code:
CREATE OR REPLACE VIEW fhr_current_show_view AS
SELECT f.title AS title,
f.description AS description,
f.id AS show_id
FROM fhr_show_info f
WHERE f.active = '1';
Exmaple records:
Code:
0, 'Regular Rotation', 'FesterBot selections and listener requests', 2, 1
1, 'Artist Hour', 'An hour of songs by a FesterBot selected artist', 25, 0
5, 'Guitar Mania', 'Get out the air guitar and wail away with these masters of devices with wires that vibrate', 27, 0
9, 'Surf Rock', 'Whoa! Gnarly dude! Surf's up and hang ten in the tube! Don't soon forget about the sea...', 33, 0
3, 'Classical Classics', 'Classic rock played classically. Now that's class!', 24, 0
6, 'Hawaiian Style', 'Traditional and Contemporary Hawaiian music to sooth your soul. Wish you were here.', 28, 0
7, 'Instrumental Show', 'Give the singer a tambourine cuz we don't need no stinkin' words! ', 29, 0
_________________
- Steve Kunitzer
- SVS (Spacial Volunteer Support) / Forum Administrator

