General :: Limiting Amount Of Bookings Per Course To 50
Jun 27, 2013
I have Trainee, Staff, Course, and Booking tables and forms. Everything is working fine but I want to limit the amount of bookings per course to 50, how would I go about doing this?
View Replies
ADVERTISEMENT
Apr 25, 2005
Hey! I'm doing Computing AS level and the coursework is to create a system for "Terry's Turkey". This is basically my first introduction to Access, and our teacher is little to no use!
After alot of work working out things in access and reading alot of books, other than creating the switchboard, theres only a few things left to do!
The first is to limit the amount of "turkeys" that can be ordered. I have 2 tables that this envolves... Order and Customers, they have a one to many relationship (each customer may place one or more orders, each order must be placed by one and only one customer). They are linked by Customer ID. I need to set two limits, I guess by a validation rule of some kind. The first is that each Customer can place no more than 5 orders. The second is that their can be no more than 40 orders in total. A slight complication to this is that a customer can "cancel" an order, in this case its marked as cancelled (theres a yes/no field called Active to determine this), and ideally, these wouldnt be included in the counts.
So far I have the following as a query, though I have no idea how to put this into a validation rule
SELECT Count(Orders.OrderID) AS Var1
FROM Orders;
I guessed that to expand this to not including inactive orders something like
SELECT Count(Orders.OrderID) AS Var1
FROM Orders
WHERE active="yes";
Any help at all would be most appreciated! I have spent many hours pondering over this is and looking at as many access sources that I can! I think this is my last resort :(
View 3 Replies
View Related
Feb 26, 2014
I have an inventory database with a few tables:
1 with product info
1 with customer info
1 with incoming stock
1 with outgoing stock (orders)
I also have 3 query's:
Total incoming stock per product
Total outgoing stock per product
Total current stock per product (based on the 2 above queries)
I'm trying to make a form through which orders can be placed, and I want to limit the amount that can be ordered based on how much stock there is.
I've been told I can use the 'before update' event on the form to achieve this, but where to start. Do I use a Macro, an Expression, or do I need code?
Also, currently the record source for this form is the outgoing stock table, but I guess I'll need to add my 'current stock' query to the sources before this can work? And maybe even my other 2 queries because my 'stock' query is based on the other 2? But I can't really seem to get that to work either.
View 4 Replies
View Related
Jul 17, 2014
I am trying to make a report in which I can see the amount of money that I have to pay weekly to an employee. To explain myself clearer, I have different rates for each employee. For example:
NameNormalPayRateVacationPayRateSickPayRateOvertimePayRateStandbyPayRate
John Smith$15$10$15$30$8
Ken Jonson$10$8$10$20$8
I am doing this in a query. So what I want to be able to do is, for example, take 4 hours that the employee worked at NormalPayRate and multiply it. But if tomorrow the employee worked at a different rate, for example 3 hours overtime, I want those 3 hours multiplied by OvertimePayRate.
The way I saw it on my Google researches, is that they have only one rate and the amount will be [SumOfHours]*[Rate]. But how can I tell my query to skip, for example, one rate because the employee didn't work at that rate that day. So I can have different amount for the different rates.
By the way, entering the information I can divide at what rate the employee worked x day. So if the employee work 6 hours at regular, and later on 4 hours at standby, I have those information separated in my table.
Results that I am getting: I can easily get the amount in money multiplying the whole hours by a rate, so my result in my report will be multiplied by the same rate.
I am using Access 2013 ...
View 2 Replies
View Related
Jul 21, 2015
I have One table(and designed form from it) in which i have recording the daily transactions(it is like a daily book). Daily transactions took place like Purchase of items of Amount 45, sale=70, sold on account=100 etc.
What problem i am facing is: I would like to Add Cash In Hand amount and would like to show it on my form. When day end I would like to move remaining cash In Hand on separate column of that date. The next day i would like to take the previous Remaining Cash in Hand as Cash In Hand at Start for next date and so on.
View 2 Replies
View Related
Jun 23, 2014
In form (datasheet) I have a three columns "RightColors", "LeftColors" and "AmountOfColors"
I want to do something like this:
If I fill 'RightColors' "red;green;blue;", and fill 'LeftColors' "orange;" then in 'AmountOfColors' column should be "4". Sometimes I can fill only 'RighColors' or 'LeftColors;
I think I should add code in after update event. Is this possible to build code which can count colors using ";"? I need loop for this, right?
View 2 Replies
View Related
Apr 1, 2014
I need to minus one amount from another in my subform.
How to do that and which command to use? Sum?
Also should I go to criteria and do it there?
View 2 Replies
View Related
Feb 18, 2013
I work in the Insurance Industry and I am having a hard time trying to find the formula for finding the answer to the below issue I am having.
In a table I have 4 columns:
1st: Total # of Claims (Claim Count)
2nd: Total # of Items (Item Count)
3rd: Item % of Claim Count
4th: Average # of Items per Claim (This is the number which I am trying to get)
Is there a formula which could give me the "Average # of Items per Claim"?
View 3 Replies
View Related
Oct 16, 2012
Calculation : In the event the null, is will become 0.
OT Qty: Nz([Qty(Overtime)-Nz([Qty(Work Hour)])
Is work to calculated the OT amount. How to set the value become zero in the event the the Qty(Overtime) was null.
View 4 Replies
View Related
Sep 17, 2014
I currently have a drop down box with four options in there and the options are:
Low
Minimum
Medium
High
However when i change the options in the table to:
Low
Moderate
Significant
High
it comes up with the error message: the field is too small the accept the amount of data you attemtpted to add. Try inserting or pasting less data.
I do not understand what is wrong with the second option of words? The maximum for characters is set to 255 so i am not sure why it is coming up with that error message.
View 4 Replies
View Related
May 23, 2013
I have made a basic form and use it a log on screen. This requires the user to in put a user name and a password before gaining access to the main database.
The background to the form is a table where the users details are entered including the i enter the user name and password.
Is there any way to add a counter that is only visible in the table, so I can report on the different users.
View 14 Replies
View Related
Mar 23, 2013
I am trying to get deposit amount for the current month but results are in accurate i am using this
DSum("[Amount]","[income]"," [trans_type] = 'deposit'" AND "Month([dep_date]) =" & Month(Now()) AND " Year([dep_date]) =" & year(Now()))
View 3 Replies
View Related
Mar 5, 2007
im making a system and part of that system is the booking of the library
2 classes can be in the library at once
i want a way where if a 3rd teacher tries to book a slot then theyll be told its not available
if only one class was allowed itd be easy, by using a compound key
but cos 2 classes are allowed this is a bit hard for me lol
trying to think of a way to allow 2 bookings but not more
any ideas?
thanks
View 7 Replies
View Related
Apr 16, 2005
hi guys nice site you got here.
I need a bit of help its been over 2 years since I used access in college so have forgot most things.
I want to stop people from making double bookings at the same time on the same date.
I have the following
Booking ID
Teacher ID
Class Room ID
Date Booked
Booked Date
Start Time
End Time
so the booked date, start time and end time is what I need to look but not sure, should I index (no duplicates) for them three?
thanks for the help
I realise there are posts about bookings but more help would be great :)
View 2 Replies
View Related
Mar 19, 2008
Just a small query for today (if you pardon the pun)
basaclly my problem is, i am creating a booking system, and i want the total for the length of stay;
attributes are
Date Arrive | Date Depart | Room Number | room price
i want to add an total column at the end (i was using the query by example builder) and tried [datedepart] - [datearrive] * [roomprice]
this however doesn't always work well, is there any other way of doing the same function? i can use SQL if that makes life easier
cheers for any response
View 11 Replies
View Related
Mar 29, 2007
I am trying to create a query that will count the number of bookings in january and a seperate count for the number of bookings in february from a table called booking order. im using the start date as the date to tell which month the booking was in.
This is what i have come up with but it doesn't work and i am not to sure where to go from here.
select count(jan.[booking no]), count(feb.[booking no]) from [booking order] jan, [booking order] feb
where jan.[booking no].[start date] > 31/12/2006 and < 01/02/2007
and feb.[booking no].[start date] > 31/01/2007 and < 01/03/2007;
View 6 Replies
View Related
Nov 10, 2007
Dear Programmers,
I would like to display a page that tells the user that there are no "bookings" for TODAY. It is a restaurant booking database which I have nearly completed. When there are bookings for TODAY, it shows a table with the customers booked for today (that's working ok), but if there aren't any for 'today' when I open that page, it just shows the headings of the table with no customers. I'd like to just display a message (and no table elements) when there aren't any bookings for today. Pretty confusing explanation? sorry bout that.
Of course I'm using a MS Access DB and .asp
Any suggestions?? Thanks very much.
Rod.
View 1 Replies
View Related
Feb 15, 2006
Could someone check the following code. i've set up a form for creating regular bookings, and have a field, for which you type in the frequency in days you want the bookings for. (ie, 7 days for every week on that day, 14 for every two weeks etc...) and it seems to work, however it just alters the one record, instead of creating entirely new ones. Could someone please help:
Private Sub cmdCreate_Click()
Dim date2 As Date
Dim period As String
Dim cost2 As Currency
Dim frequency2 As Integer
Do While year = actual_year
date2 = Date_For
period = Time_Period
cost2 = Cost
frequency2 = Frequency
DoCmd.OpenTable "tblRegularBookings"
DoCmd.GoToRecord acDataTable, "tblRegularBookings", acNext
Date_For = date2 + frequency2
Time_Period = period
Cost = cost2
Frequency = frequency2
DoCmd.Close acTable, "tblRegularBookings"
Loop
End Sub
Also, one of the other problems i'm trying to solve is for those who want to create a regular booking but on say every third monday of the month for example.
Thanks very much
View 2 Replies
View Related
May 2, 2013
I want to create a calendar to show some bookings. I have a table [tblShootDates] with some fields, the most important being [ShootDate]. I also have a [ShootDateID] which is an Autonumber and is the Primary Key. I should add that it has a Prefix "Shoot ID" 000000.
I want the calendar to show each day that a booking has taken place and the text to show is the [ShootDateID]
View 1 Replies
View Related
Oct 24, 2006
I have a form which allows the user to book rooms.
On this form, there are the following fields:
BookingID: (Autonumber)
RoomID: Text box
Time:Text Box
Date: Text Box
Class: Text Box
Teacher: Text Box
The form adds this information to the Booking table.
What I'm looking to do is prevent the user from double booking a room,like being able to check if the Room is already booked at that time and date, before the new information is added to the table and the room becomes double booked.
Basically this would be checking the RoomID, Time and Date fields, as everything else is irrelevant. What would be the best way to do this?
View 3 Replies
View Related
Jun 7, 2013
I work across a number of small venues which have art cases that can be booked for displays. I am trying to build a simple data base to report what space is available and also what art is currently being displayed. The art is usually booked by month, but sometime it can be booked for a week etc.
I have set up 3 tables
Art Inventory
Art Cases by Venue
Art Case Bookings
In the art case booking form, I have set up the start and end date but I cannot figure out how to avoid double bookings of a case? Once I have that worked out I believe I know how to build the required reports for my needs.
View 4 Replies
View Related
May 23, 2014
I am supposed to make a database for a hotel system, how I could prevent double bookings.
My Reservation Table has the following fields:
Reservation No. (PK)
Room No. (FK)
Customer ID (FK)
Payment ID(FK)
Reservation In Date
Reservation Out Date
Together with preventing double bookings is there a way automatically that can mark in the Room Table, the status as "available" or "booked" automatically by looking at the date today?
View 3 Replies
View Related
Jul 26, 2007
Hi
First timer question
After searching for Nemours combinations I am now asking for some help
I have tried combinations to get a expression to give me a list of bookings staying tonight
The fields in the table I use to store the Start & End date of the booking are below
[CheckInDate]
[CheckOutDate]
I have lost my way with Between And <= etc
A wee pointer would be appreciated
Thanks
View 2 Replies
View Related
Oct 21, 2005
I'm trying to limit the amount a user can enter into a employee discount field in a table. I would like to set up a validation rule in the table to limit the discount to no greater than $0.20 or 20 cents. Anyone have any recomendations? Thanks..
View 1 Replies
View Related
Feb 14, 2008
Hello, I need help. I have two tables.
horse_entries
ent_HorseName (PK)
ent_entries
horse_information
inf_HorseName (PK)
inf_Ground
inf_Notes
It is a many-to-many relationship. When I open a table and enter a record there is a small + sign that allows me to open up the rows from the other table to enter directly into it. Can this be turned off? Also I can enter more than one record through this way. I only want one entry in inf_Ground, inf_Notes and inf_Entries for each HorseName. How would I do this? As you can tell I am completely new to Access and trying to learn. Thanks :)
View 2 Replies
View Related
Nov 8, 2005
Im doing a database booking system and i need to limit the amount of people to 160 per night. At the moment i have a query that sums up the bookings per date but i dont know how to then limit this column to 160.
View 2 Replies
View Related