Selecting records by date!

  • Thread starter Niklas Östergren
  • Start date
N

Niklas Östergren

Hi!

Is it possible, in SQL, to select the records, in a table, which have the
newest date?

In my table <tblMemberValidation> I store validation date for a member,
among other data (such as <Fee>, <MemberCard>). I store a record each time a
member pays his/her memberfee

I want to select only the records with the memberhip that is valid. = Which
hase a ValidDate > Date(). On the other hand I don´t whant to show more than
one record for each member. Ex:

MemberNo 1 has payed for membership with validation date 2004-04-30 (which
was payd for spring last year). Now, in marsh we recive next memberfee for
next 12 month so we create a new record for MemberNo 1 with validation date
2005-04-30. In this case both memberships are valid since they are greater
than today´s date but I only whant too show the latest one (validation date
2005-04-30).

Is this possible in SQL? If, how?

TIA!
// Niklas
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top