Using MS Access/Min If



I have got a system in a database however there is one part that I can not figure out how to get working.

I have got the concept working in excel, using the formula below


Essentially I have a table as follows,

AutoNumber as TransferNo
Date as TransferDate

In my system the first 5 customers are charged one standard rate with any after at a disocunted rate.

In a month customers will transfer, say customer 1 transfers then customer 6 will then take the standard rate etc.
However customers transfer out of sequence so I cant simply start from 6 and add 1 to each customer that transfers out.

Essentially I need to know for each transfer which customer replaced them at the standard rate, so if transfers are ordered by date it is the min number (greater than 5) which hasnt already been transferred out.

I am having real trouble getting my head around it in access though, is something like this possible?

I'm not quite following the structure and workflow. What does your app do? How are customer's entered. Is it first come first served with respect to standard/discounted rates? I don't understand; "which customer replaced them at the standard rate".  

Using MS Access

All Answers

Answers by Expert:

Ask Experts




I can answer almost all types of questions relating to Microsoft Access usage and application design. My strengths are database and interface design.


I've been designing databases for over 25 years working with dBase, FoxPro, Approach and Access.

Author of Microsoft Office Access 2007 VBA
Techncial Editor for Special Edition Using Microsoft Access 2007 and Access 2007 Forms, Reports & Queries From Que Publishing

Brooklyn College BA

©2017 All rights reserved.

[an error occurred while processing this directive]