Easiest Way to do a report (1 Viewer)

K1Kingy

Registered User.
Local time
Today, 12:50
Joined
Jun 12, 2008
Messages
20
I have a library database, with several tables. I am wanting to produce reports for the students who have overdue books.

I am completely new to reports, so any help on the easiest way to go about doing this would be a great help. Thanks

EDIT: I'll post what i current have so as to help a little.

I have created a query which selects any over due books from the 'tbl_issue' table.

When i run the query I get back,

issueID, studentID, bookID, issueDate, issueDueReturnDate

So what i need to do with this query is then select the information from the corresponding tables that have relationships with the tbl_issue.

Eg: for all overdue books select student information from tbl_students where studentID = studentID
same with all books.

Then i can produce a report saying something like:

Dear [studentName],
You have [x] number of books overdue, please return them as soon as possible.

[bookTitle] [issueDueReturnDate] [NoDaysOverdue]


Thanks heaps,
Kingy
 
Last edited:

statsman

Active member
Local time
Yesterday, 20:50
Joined
Aug 22, 2004
Messages
2,088
In your query you should have both tables (books and students). They should be linked on the StudentID field.

Try the following for your report

Page Header

(="Dear "&[StudentName])

(="The following books are overdue")

Detail

issueID, studentID, bookID, issueDate, issueDueReturnDate
 

K1Kingy

Registered User.
Local time
Today, 12:50
Joined
Jun 12, 2008
Messages
20
Ok that makes a bit of sense.

By doing this, will it limit the report to only students with overdue books? By running the query i made (Selecting overdue books) will that make the report just show what i want it to show?
 

statsman

Active member
Local time
Yesterday, 20:50
Joined
Aug 22, 2004
Messages
2,088
If your query is currently only showing overdue books, then that is what your report will show.
 

K1Kingy

Registered User.
Local time
Today, 12:50
Joined
Jun 12, 2008
Messages
20
Thanks statsman this is coming together nicely. I have one more problem though. When running the report if a student has more than 1 book overdue, it is creating a report for the student twice. How do i stop it from creating the report twice and just writing you have 2 books overdue.
 

wiklendt

i recommend chocolate
Local time
Today, 10:50
Joined
Mar 10, 2008
Messages
1,746
would "GROUP BY StudentID" work in the query/SQL?
 

Users who are viewing this thread

Top Bottom