[AccessD] Range of Values in Access Switch Function

Steve Schapel steve at datamanagementsolutions.biz
Thu Sep 16 16:58:14 CDT 2010


Hi Brad,

Ok, I understand.

If you are really using digits in a text field, the simple > and < idea I 
gave you will only work if the numbers in your real example don't go beyond 
"9".  If they do go beyond "9", it is certainly possible to do what you 
want, but some further tweak will be required, either using the Val() 
function or Format() function within the Switch.

Regards
Steve

-----Original Message----- 
From: Brad Marks
Sent: Friday, September 17, 2010 9:28 AM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] Range of Values in Access Switch Function

Steve,

Thanks for the example.  This works nicely in the query.

The reason that I am experimenting with the Switch Function instead of
the IIF approach is because of the complexity of the "real" query.  The
example that I posted is just a small part of a much bigger and more
complicated SWITCH statement.

Thanks again for the assistance.
Brad





More information about the AccessD mailing list