Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

This topic is 6809 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted (edited)

I need to find how many people voted in atleast 3 of the last 4 elections, but Im not sure about how to go about doing the Find in FM8.

I have seperate fields for every election, and the data looks like this:

VoterID---Gen05---Gen04---Gen03---Gen02

001134---G5------------G3--------G2

002459------G4---------G3--------

The field is empty (null) if they did not vote in that particular election.

Any suggestions? I've reading the Help section a few times and can't seem to grasp how to find if they voted 3 times in any one of the 4 elections.

Thank you...

Edited by Guest
Posted

You could do a calculation field along the lines of (it would be a number result):

If( Gen05 = ""; 0; 1) + If( Gen04 = ""; 0; 1) + If( Gen03 = ""; 0; 1) + If( Gen02 = ""; 0; 1)

That would give you a number from 0 to 4, letting you know how many times they voted. I'm not sure if there's a cleaner calculation for it, but that should do it!

Posted

You could also use:

not IsEmpty ( Gen04 ) + not IsEmpty ( Gen03 ) + not IsEmpty ( Gen02 )

But Jess, having each election as a field will increase your workload by 50 times! Every time you add an election, you will have to 1) add a field, 2) add that field on all your layouts throughout your solution, 3) modify every one of *these* types of calcs, 4) constantly create *these* types of calcs in an attempt to generate your summary figures and 5) you will never be able to generate reports.

Each election should be a related record. Truly. I realize sometimes we can't change things already established but if not ... change it very soon!

LaRetta :wink2:

Posted

MMS6F

Thanks a million. That did the trick entirely as long as I do my find with the greater than or equal to operators.

Laretta,

I definitely see your point and wish I could change it, but this is how we are getting our data from the County Clerk. Thanks for your insight (as always)!

Jess

Posted

not IsEmpty ( Gen04 ) + not IsEmpty ( Gen03 ) + not IsEmpty ( Gen02 )

Take a look next to the third dot in description dept. of this:

http://www.filemaker.com/help/Functions%20Ref3.html

Using "not IsEmpty" is bound to be slower due to number of functions involved!

--sd

Posted

Thank you, Soren!!

I prefer boolean tests. But I wasn't sure if those fields would always contain an integer or if they might contain only text or a G0 (as in year 2000). It *appeared* that they would contain Gx or nothing, but Sin of Assumption has biten me before ...

Count() - of course! :wink2:

I was focused on getting to the issue of multiple fields.

This topic is 6809 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.