Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6758205
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T13:45:11+00:00 2026-05-26T13:45:11+00:00

I know that there are quite a few different topics out there but I

  • 0

I know that there are quite a few different topics out there but I don’t believe they are exactly what I’m looking for.

I need to make a database using MySQL for a club I’m in. I want to create a webpage that the Secretary can log into and take attendance for the meeting. First off I need to know what exactly I would need for creating the table.

I was thinking something like

CREATE TABLE 'Members'('memberName' VARCHAR(40) NOT NULL, 
    '11/1/11' INT NOT NULL DEFAULT 0, 
    'totalAttendance' INT NOT NULL DEFAULT 0, 
     PRIMARY KEY('memberName'), UNIQUE INDEX 'memberName'_UNIQUE('memberName' ASC));

and just keep adding columns for the date using ALTER TABLE 'Members' ADD '11/8/11' INT NOT NULL DEFAULT 0;

I was going to use PHP to create the column and change the default 0 to a 1 if they attended (not exactly sure how I was going to do that but I was thinking some check boxes and if they are checked edit that column for that name?) So something like mysql_query("UPDATE 'Member' SET 'meetingDate'='1' WHERE memberName='nameOfMember'")
or die(mysql_error());
I believe.

What I really need is a way to count across each column to count the total number of times each member has attended and then placing that into the totalAttendance column.

Can someone help me out with that? I’m thinking it is a really easy statement I’m just not asking Google the correct question. Thank you for any help you can give.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T13:45:12+00:00Added an answer on May 26, 2026 at 1:45 pm

    I’d suggest you set up something like this:

    id    |  MeetingDate |    MemberName    |    Present
     1    |  2011-11-01  |    John Doe      |       1
     2    |  2011-11-01  |    John Smith    |       0
     3    |  2011-11-01  |    John Jackson  |       1
     4    |  2011-11-02  |    John Doe      |       0
     5    |  2011-11-02  |    John Smith    |       1
     6    |  2011-11-02  |    John Jackson  |       1
     7    |  2011-11-03  |    John Doe      |       1
     8    |  2011-11-03  |    John Smith    |       1
     9    |  2011-11-03  |    John Jackson  |       1
    

    So you’d have a row for each member for each meeting whether they attended or not. My guess is you’re not going to have millions and millions of rows with this system, so don’t worry about performance.

    You can get the total attendance for a member with something like:

    SELECT SUM(Present) as total FROM attendance WHERE MemberName = 'John Doe';
    // returns -> 2
    

    You can get the total attendance for a meeting with something like:

    SELECT SUM(Present) as total FROM attendance WHERE MeetingDate = 2011-11-01;
    // returns -> 2
    

    You can get all of the members that missed a specific meeting with something like:

    SELECT MemberName FROM attendance WHERE Present = 0 AND MeetingDate = 2011-11-01;
    // returns -> John Smith
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I know that there are lots of examples out there on this, but they
I know that there's quite a few subjects similar to this one, but none
I know there are quite a few questions concerning access violations, but I have
I believe that this question has been asked in a few different forms, but
I've been working with app engine for quite some time, I know that there
I know that there are lot's of questons on this, but all seem to
I know that there are others posts with solutions on the site but i
I know that there can be multiple values for an email, but I'm not
I know that there are many Delphi database related questions available, but I'm considering
I'm looking to learn LINQ, but I'm finding that there is a lot more

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.