Results 1 to 7 of 7
  1. #1
    rtinsky is offline Novice
    Windows 8 Access 2010 32bit
    Join Date
    Jan 2014
    Posts
    6

    How to create form with fields from multiple tables

    I need to create a form that will display a list of contacts from the contact table and then allow you to enter attendance for the dates in the attendance table. Whenever I try to create this form, all I get is the heading with no content. I have linked the ID field from the contact table to the contact field of the attendance table. The attendance table has no entries as no attendance has been taken. Do I need to have a record in the attendance table for each contact in the contact table? If so, how do I get those records created? And how do I get one form that will allow me to enter attendance for all the contacts?

  2. #2
    CJ_London is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,932
    the rule is one form, one table. So if you have multiple related tables, use a form for the 'main' table and subforms for the other tables

  3. #3
    orange's Avatar
    orange is online now Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,870
    Perhaps you could tell us a little more about your Contacts and what exactly they are attending?

    If you have Meetings on scheduled dates, or Events of some sort, then you might consider an additional table.

    eg: Contact--->ContactAttendedMeeting<----Meeting

  4. #4
    rtinsky is offline Novice
    Windows 10 Access 2016
    Join Date
    Jan 2014
    Posts
    6
    Quote Originally Posted by orange View Post
    Perhaps you could tell us a little more about your Contacts and what exactly they are attending?

    If you have Meetings on scheduled dates, or Events of some sort, then you might consider an additional table.

    eg: Contact--->ContactAttendedMeeting<----Meeting
    The attendance file is for recording their Sunday attendance at church. There is a field for each date of the year in the attendance table. I would like a form that allows me to enter the contacts attendance for each week or field in the attendance table.

  5. #5
    ssanfu is offline Master of Nothing
    Windows 7 32bit Access 2010 32bit
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    There is a field for each date of the year in the attendance table. I would like a form that allows me to enter the contacts attendance for each week or field in the attendance table.
    This sounds like you are "committing spreadsheet"! This means you have designed your Access tables like a spreadsheet. Spreadsheets are typically short and wide. Access tables are typically designed Tall and narrow.
    A spreadsheet design in Access is not a normalized design.



    Consider:

    tblContacts
    ----------------
    ContactID_PK (autonumber)
    ContactFName (text)
    ContactLName (text)


    tblAttendance
    ---------------------
    AttendanceID_PK (autonumber)
    ContactID_FK (long integer) (foreign key field to tblContacts)
    AttendanceDate (date/time)

  6. #6
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,770
    So there are 52 fields - one for each Sunday date?

    If you stick with this design (not advised) then why bother with 2 tables? Just have one big 'flat file' table - like a spreadsheet.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  7. #7
    orange's Avatar
    orange is online now Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,870
    If you have convinced yourself of HOW you're going to do this; and that is like a spreadsheet; then use a spreadsheet (Excel).

    Try to separate What you want to achieve from HOW it should/could be done.

    If you want to use Access, then review some database design articles, create a sample model and test with sample data, then build the database. If you don't want to learn the basics of database, then don't try to use Access (or any DBMS).

    The analogy is using a hammer to drive screws, yes it will work (once), but use the right tool for the job.

    Good luck with your project.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 8
    Last Post: 04-02-2016, 04:56 AM
  2. Replies: 3
    Last Post: 05-15-2013, 07:59 AM
  3. Replies: 1
    Last Post: 12-18-2012, 02:50 PM
  4. Replies: 1
    Last Post: 10-28-2012, 07:23 PM
  5. Multiple tables to create one Form??
    By Gravity101 in forum Forms
    Replies: 2
    Last Post: 06-02-2011, 06:37 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums