473,385 Members | 1,353 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

college library borrowing system

i am in the process of creating a basic library borrowing system using access this is a project.

i have created my tables, as well as some forms and have ran some queries.

i would like my system to calculate when a book is overdue, and how much will have to be payed.

what do i use to do this queries??? VBA???

any help greatly appreciated
Dec 5 '07 #1
2 8595
Nathan H
104 100+
i am in the process of creating a basic library borrowing system using access this is a project.

i have created my tables, as well as some forms and have ran some queries.

i would like my system to calculate when a book is overdue, and how much will have to be payed.

what do i use to do this queries??? VBA???

any help greatly appreciated

You can use a query...(or VB but here is a query)

Add this column in your book query

Late_Fine: ((Date())-[Table1]![return_date])*0.05)

0.05 is however many cents you charge per day late fee, here would be 5 cents.
Dec 5 '07 #2
Hashtt
1
i am in the process of creating a basic library borrowing system using access this is a project.

i have created my tables, as well as some forms and have ran some queries.

i would like my system to calculate when a book is overdue, and how much will have to be payed.

what do i use to do this queries??? VBA???

any help greatly appreciated
************************************************** ************************************
Dear Nelly2007

I got to know this forum today and I have admired it. This is my first attempt to respond and I’m not an expert on MS Access but let me try to reply to your questions in a simple way:

From your closed thread I got more information helped me to relpy:

1. How to automatically display in a form, when a book is overdue

Step 01: in the Loan table in addition to the DateDue you need to have a flag to determine those who returned their books from others who don’t yet did that. The field can be a flag (Yes/No type). Let us call it Returned.

Step 02: Using the design view you can create a query (Let us called QryDateDue) based on your three tables to show the student Name, Book Details, date loaned, date due and Returned.

Step 03: Add an expression in the criteria grid under the field Date Due as follows <Date(). The Date() function will return the date of today. The whole expression will help you to get those who are overdue. It is imperative that your computer date and time zone are correct.

Step04: Add an expression in the criteria grid under the field Returned as follows No. This will exclude the records of those who already returned their books in the past. This is important because obviously the DateDue in the records of those who returned their books is overdue but the difference that they returned their books.

Step 05: You can create a report and base it on the mentioned query in step 01. The report will show those who are overdue.

2. How to calculate how much the fine is going to be
In this situation, the assumptions and the ways are many. Here after is one way which is defiantly is not perfect hoping others may contribute with a better solutions.

Assumptions for this scenario are as follows:

A01: You are using the same fine for all books i.e. the book title have nothing to do with the amount of the fine per week.

A02: Sine it is not advisable to hardcode the fine price in a query grid you may need to create a table containing the prices for different fines. For example you may create the following fields in the tblFine: FineOneW, FineTwoW, FineThreeW, FineFourW, and FinalFinePrice as the last and biggest fine. This will enable you to edit the fine price from time to time using a form based on the created table

Step 06: Assuming the two scenarios were fulfilled, you can go back to your query QryDateDue in the design view and modify it by adding the table tblFine without linking it to any of the three tables.

Step 07: Create a calculated field which will calculate the fine for each week delay. To do this in the query grid and in an empty column/field type the following equation Fine: IIf((Date()-DateDue])<=7,1*[FineOneW],IIf((Date()-[DateDue])<=14,2*[FineTwoW],IIf((Date()-[DateDue])<=21,3*[FineThreeW],IIf((Date()-[DateDue])<=28,4*[FineFourW],[FinalFinePrice]))))

The above equation is calculating the delay in weeks but it can be modified easily to be in a daily base if needed.

Step 08: you can create report based on the query to group and display those who are over due and sum up their fines if they were borrowed more than one book a time.


I hope this will help especially English language is not my first language.

Thank you and best regards
Dec 6 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

14
by: Jason Daly | last post by:
I'm a freshman at college as a computer science major. I'm not sure it has what I want. Does anyone know if a major commonly exists in web design (focusing in server side languages)? I want to...
2
by: TO | last post by:
Hi everyone, I am a Sr. Software Architect and a College Professor in Toronto. I've been working with .NET since 2001 (Beta1 version), and since then, I've been promoting .NET Platform...
2
by: Dave in Dallas | last post by:
http://tinyurl.com/a65kn 'Smart' classrooms, ritzy dorms lure 'Millennials' Local colleges are rushing to build high-tech classrooms and plush dormitories for a new breed of students who grew...
5
by: Paul | last post by:
I am creating a Program for college, in which the Program will read a Folder and create a HTML page from the pictures that are storrd in that folder. .. What would be the best way to do it in VB...
44
by: Jeff | last post by:
Hi I have a library mde that is used with some customer databases and I found out that another developer discovered it while doing some maintenance work on an old database for the same customer...
66
by: stryfedll | last post by:
Sorry this isn't directly concerning a programming language but I wanted to reach real programmers. I am in college right now and am not really interested in investing 3 more years of my life for a...
72
by: jacob navia | last post by:
We have discussed often the proposition from Microsoft for a safer C library. A rationale document is published here by one of the members of the design team at microsoft:...
8
by: Surya Dutt | last post by:
Hello, Did someone happen to come accross and algorithm or a C++ program that simulates the Smith Collge Diploma problem? "At Smith College, the graduation exercises traditionally proceed as...
204
by: Masood | last post by:
I know that this topic may inflame the "C language Taleban", but is there any prospect of some of the neat features of C++ getting incorporated in C? No I am not talking out the OO stuff. I am...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.