Jump to content

Recommended Posts

Posted
Hi @jessica! I have some SQL snippets to run directly in the database, which may produce what you want. I'll have a look and let you know!

 

Have you had any luck with the SQL?

 

Thanks

Posted

Hi @jessica! Yes, sorry.. here it is! :)

 

SELECT 
rooms.name AS Room,
IF(departments.name IS NULL, "No department", departments.name) AS Department,
COUNT(bookings.booking_id) AS Total
FROM bookings
LEFT JOIN users ON bookings.user_id = users.user_id 
LEFT JOIN rooms ON bookings.room_id = rooms.room_id 
LEFT JOIN departments ON users.department_id = departments.department_id 
WHERE bookings.date IS NOT NULL 
AND bookings.date BETWEEN '2016-09-01' AND '2017-07-31'
GROUP BY rooms.room_id, departments.department_id
ORDER BY rooms.name ASC, departments.name ASC

 

That should give you a result which lists the room, department, and total number of bookings between the given date range. You can remove the "AND bookings.date ..." line if you aren't concerned about that.

Posted
Hi @webman

Currently getting the following error when trying to run the query. Any ideas?

[ATTACH=CONFIG]39266[/ATTACH]

 

Hi @jessica, that's odd.. I have ran that on two test databases and it runs OK. It could be the version of MySQL you're using. Does this one work any better?

 

SELECT `rooms`.`name` AS "Room",
IF(`departments`.`name` IS NULL, "No department", `departments`.`name`) AS "Department",
COUNT(`bookings`.`booking_id`) AS "Total"
FROM `bookings`
LEFT JOIN `users` ON `bookings`.`user_id` = `users`.`user_id`
LEFT JOIN `rooms` ON `bookings`.`room_id` = `rooms`.`room_id`
LEFT JOIN `departments` ON `users`.`department_id` = `departments`.`department_id` 
WHERE `bookings`.`date` IS NOT NULL 
AND `bookings`.`date` BETWEEN '2016-09-01' AND '2017-07-31'
GROUP BY `rooms`.`room_id`, `departments`.`department_id`
ORDER BY `rooms`.`name` ASC, `departments`.`name` ASC

  • 1 month later...
Posted
I am running some SQL to see all the bookings made this year, but i don't think the recurring bookings are listed correctly? Are they created in the database repeatedly for each week, or is there just one record for the whole year?
Posted
I am running some SQL to see all the bookings made this year, but i don't think the recurring bookings are listed correctly? Are they created in the database repeatedly for each week, or is there just one record for the whole year?

 

Hi Bev. The recurring bookings are essentially just one entry - with the main data being the weekday and timetable week - rather than the date.

  • 6 months later...
Posted (edited)

Hi all. My institution is having a tedious task in managing classroom booking. So I decided to try finding for a solution, even tho i have practically ZERO knowledge on programming. :( So, yesterday was the start of a very hard non-stop trial and error.

 

After scouring the internet for hours, i decided to place my bet on classroombookings as having the best features with the most user control possible. Since I never use MySQL before, I used WampServer to reduce its technicality. It took me a whole day to reach the final login page. I got to say I encountered almost all what the beginners like me encountered in this forum (error 1054 & 1067 were the hardest! :mad:) and managed to solve almost all of them, thanks to everyone. What i'm trying to say is that, classroombookings is easy if you spend a bit of your time finding the solution at the right place. Thanks Webman for this incredibly easy solution.

 

But, I think I am stepping into the wild again.. not sure how to make all the hard work into a real website. Any idea? I know the question sounds stupid, but just give me a hint and i'll try to figure it out. :)

Edited by seventh7
Posted

Does you MIS system not do room booking?

 

Ideally any booking systems needs to be tied to the timetable/MIS so that if classes or teachers are moved, etc and room bookings made any student or teacher looking at this timetable will see the "actual" rooms he is in that day.

 

A stand alone room booking system must mean that you are going to keep looking in two places all the time.

 

...Do other MIS systems really not do room booking?

  • 4 weeks later...
Posted

@webman

 

Is there a way to allow classroom bookings to email a specific teacher? For example, we have a staff member who has a job which involves putting up display work around our place. They have asked if it would be possible for the system to email them when a booking is made - a bit like a ticketing system?

 

Regards

Posted

Hi @timbo343! I'm afraid there isn't anything like that in CRBS at the moment! :(

 

How's your PHP these days? :) It probably wouldn't be too difficult to do; the main things being: deciding under which conditions to send it, defining who it goes to, and what's in it!

Posted
Hi @timbo343! I'm afraid there isn't anything like that in CRBS at the moment! :(

 

How's your PHP these days? :) It probably wouldn't be too difficult to do; the main things being: deciding under which conditions to send it, defining who it goes to, and what's in it!

I thought that would be the case, nevermind.

 

As for my php skills, they are none existant so its a no go.

  • 2 months later...
Posted

Sorry for the necro(ish - is two months really 'necro'?)bump.

 

I've recently been looking at other room booking systems as some of our staff are asking for additional functionality that doesn't exist with @webman's ClassroomBookings* and hitting a bit of a brick wall here.

I've tried Booked (formerly phpScheduleIt) and MRBS but neither seem to really be made to fit schools. MRBS has no way of doing school holidays and I can't find anyone who's written a plugin for that, and I'm having issues with getting Booked working with LDAP and again there's the issues of breaks in service.

I've also tried OxAldo Room Booking System but I can't get Lucee/Tomcat working so that's dead at the get-go.

 

So what else are people using? Are there other systems that I'm missing?

Did ClassroomBookings v2 ever emerge? (I know Craig moved away from Education so if you're not working on it any more that's cool :))

 

* To clarify, I'm not slating the software at all. It's been fantastic, our staff love it, it does what it needs to and it does it well. I genuinely recommend it. It's just that some of our staff are just wanting a bit more 'meat' to the booking system like emailing Site Management if a reservation is made in the Hall, not needing to book timeslots in relation to the timetable for meeting rooms that don't house classes, and LDAP authentication.

  • Thanks 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...