Show unused values in databasejoin

chatequap

New Member
I have a list of timeslots in a table. The values are displayed as databasejoin that is rendered as checkboxes in an entertainment form. Entertainers can choose up to 4 slots.

I would like to only display timeslots that are not used by other entertainers.


The tables are as follows:

timeslots
id timeslot
1 11:00 AM
2 11:15 AM


entertainers
id group .... timeslot


Each timeslot can only be used by one entertainer. Entertainers can choose up to 4 timeslots



Thank you.
 
Last edited:
I am a little confused on the where clause. This is what I have so far:

where `id` NOT EXISTS (select `timeslots` FROM `mfd_entertainment_repeat_timeslots` where 1)

It gives an error
 
It's the wrong NOT EXISTS syntax
where NOT EXISTS (select * FROM `mfd_entertainment_repeat_timeslots` m where m.timeslots = {thistable}.id)
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top