🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.mac.databases
Article #618

Lots of nested If's in FMP

#618
From: Ainsley Calladine
Date: Tue, 12 Jan 1993 08:06
24 lines
1498 bytes
Hi!
I'm currently setting up a db in FMP2 which is largely to make data
entry by a number of novices straight forward, chances are they won't
understand the data structure at all.
In a number of cases I have fields which have up to 50 pre-defined
values (although most are <20) to choose from. These categories are then
grouped into a smaller number of categories (3-5). What I want is to
have the data entry people only choosing one of the lower categories
(using radio buttons) and the higher one being entered automatically.
I've used a field defined as a calculation with a nested 'If' statement
like this:

If (Field 1 = "X" or Field 1 = "Y" or Field 1 = "Z", "It's one of
these", If (Field 1 = "A" or Field 1 = "B" or Field 1 = "C" or Field 1 =
"D", "It's something else", "Or it's nothing"))
 
This works fine but I'm concerned that a nested 'If' testing 50 cases
might be a bit big! Also, am I right in believing that this calculation
definition is stored once and only the result is stored several thousand
times once for each record?
 
Any suggestions will be appreciated
 
Ainsley
Technical Details
Message-ID: <1itu6jINNge6@uniwa.uwa.edu.au>
Path: arc1-ca.pugleaf.net!sparky!uunet!munnari.oz.au!uniwa!uniwa!nfm

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!munnari.oz.au!uniwa!uniwa!nfm
From: ainsley@uniwa.uwa.edu.au (Ainsley Calladine)
Newsgroups: comp.sys.mac.databases
Subject: Lots of nested If's in FMP
Date: 12 Jan 1993 16:06:43 +0800
Organization: The University of Western Australia
Lines: 24
Message-ID: <1itu6jINNge6@uniwa.uwa.edu.au>
NNTP-Posting-Host: uniwa.uwa.edu.au
X-Newsreader: Tin 1.1 PL5