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 3783 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted (edited)

Hi everyone, am new to filemaker but am quickly learning as I read through posts and comments on this forum.

Am embarking on a test project to create a simple database for student records which will display either (FAILED or PASSED) from the total score of the students performance. please how do i go about this?

Edited by Lee Smith
Please do not shout your titles.
Posted

Welcome to FM Forums.

 

Naturally, your solution is going to depend on your criteria for what constitutes Pass vs. Fail.  

 

One simple solution is to have a table of test scores sorted by student ID.  Include a summary-type field that shows the Total of the test scores. Also create a global field that allows you to enter the minimum passing score.  Finally create a calculation field that evaluates:  Score_sum ≥ Pass_score.  Place On your layout add a subsummary part (when sorted by student ID), and format the field as a boolean to display either "Pass" or "Fail" on the subsummary part. 

 

Does that help? 

Posted

PROJECT SCREEN SHOT

 

I just uploaded a screenshot of my little project. Am very new to filemaker, so am not very conversant with some of the terms you mentioned in your reply..

The screenshot will help to explain my intentions better..

 

1) i want the the REMARK fields to display either PASS when the SCORES fields have values of (greater than or equal to 70)   and FAIL when the the value is (less than or equal to 69)

 

2) I want the GRADES FIELDS to change to (A,B,C,D,E,F) when the SCORES FIELDS have values of (from 70-100, from 60-69, from 50-59, from 40-49, from 30-39, from 29-0)  respectively

 

THATS BASICALLY WHAT I WANT TO ACCOMPLISH NOW...

Posted

PROJECT SCREEN SHOT

[…]

THATS BASICALLY WHAT I WANT TO ACCOMPLISH NOW...

 

A description of your file structure and/or a screenshot of your Relationship Graph would be of more use; and me seems you either have an unhealthy affinity to uppercase letters, or your caps lock key is stuck …  :laugh:

 

Am very new to filemaker, so am not very conversant with some of the terms you mentioned in your reply.

 

Nothing that can't be remedied by a little reading, study and experimenting …

Posted

ok eos, but i justed posted a screenshot of the project, anyway if that doesn't quite help, i will try to post a screenshot of the relationships..

but basically, the project has just two tables (students and courserecords) which are related with one field which is the regnumber of the students.

Posted

the project has just two tables (students and courserecords)

 

OK, so at least you haven't stuffed everything into a single table; but normally there should be (at least) 3 tables: Students, Courses, and, say, Enrollments. For example, where do you store the course name, its start date and any other data that belongs only to the course itself, and not to any student enrolled in it?

 

Let me add that you shouldn't use the student's registration number as primary key for internal relationships; use an automatically created serial number for that purpose.

 

1) i want the the REMARK fields to display either PASS when the SCORES fields have values of (greater than or equal to 70)   and FAIL when the the value is (less than or equal to 69)

 

I assume you there is one (1) Score field per CourseRecord (if a field only stores a single thing, it should be named accordingly, to avoid confusion of the kind I just experienced …).

 

Calculation field cRemark, type text! (select at the bottom of the calculation dialog), defined as

Case ( 
  SCORES >= 70 ;
  "Pass" ;
  "Fail" // note that you can use layout formatting options to display this field in uppercase 
)

 

2) I want the GRADES FIELDS to change to (A,B,C,D,E,F) when the SCORES FIELDS have values of (from 70-100, from 60-69, from 50-59, from 40-49, from 30-39, from 29-0)  respectively

 

This is the same principle, just with a few more cases to consider:

 

Calculation field cGrade, type text! (select at the bottom of the calculation dialog), defined as

Let (
  s = SCORES ;
  Case (
    s >= 70 ; "A" ;
    s >= 60 ; "B" ;
    s >= 50 ; "C" ;
    s >= 40 ; "D" ;
    s >= 30 ; "E" ;
    "F"
  ) 
)
Posted

 

Let (
  s = SCORES ;
  Case (
    s >= 70 ; "A" ;
    s >= 60 ; "B" ;
    s >= 50 ; "C" ;
    s >= 40 ; "D" ;
    s >= 30 ; "E" ;
    "F"
  ) 
)

So much grateful with your reply. with this code, I was able to accomplish the task and I have applied it to similar task as well.

 

Right now, am having problems applying this to a more direct comparison. Like I want the Point field to automatically display 5,4,3,2,1,0 respectively when the values of the Grade field is A,B,C,D,E,F respectively

 

 

Then secondly, I have tried learning some scripts or codes, but I don't seem to actually understand the scenario (tasks to achieve with them) where they can be applied. But I perfectly understood this very one you gave me, (maybe because I provided the task I wanted to accomplish with it)

Posted

Like I want the Point field to automatically display 5,4,3,2,1,0 respectively when the values of the Grade field is A,B,C,D,E,F respectively

 

You can apply the exact same calculation to that other field, but return 5,4 3… as results, instead of A,B,C …

 

Or, if you want to keep the calculated results in sync while having to define the point intervals in only one place, use either

Let (
  c = cGrade ;
  Case (
    c = "A" ; 5 ;
    c = "B" ; 4 ;
    etc.

or, a bit fancier:

Let (
  gradeList = "F¶E¶D¶C¶B¶A" ;
  ValueCount ( Left ( gradeList ; Position ( gradeList ; cGrade ; 1 ; 1 ) ) ) - 1
)
Posted (edited)

eos,

 

I applied this and it worked perfectly, but each time i modified the numeric values to Alphabets, I always get a pop up message "The specified field cannot be found" (and it highlightes the word)

 

example, I wanted to use same procedure to make a new field Remarks which should display good, better , worse  when the value of the grade field is A, B, C respectively

Edited by Lee Smith
removed the redundant information of the quote
Posted

Finally I got it working... Thanks for your help...

My Calculation Result is giving results of the form : 4.3345623 please How do I approximate it to two decimal points eg 4.35 only?

Posted

Finally I got it working... Thanks for your help...

My Calculation Result is giving results of the form : 4.3345623 please How do I approximate it to two decimal points eg 4.35 only?

 

Not sure how you arrive at 4.35 for that value … but be aware that you can simply format the display of a number field on a layout (Inspector > Data > Data Formatting, select e.g. Decimal).

Posted

It really worked... Thanks a million...

please, I want to create a custom search for my contact records. Am really having difficulty pulling it off... Is there a similar forum topic where I can learn that?

Posted

 

OK, so at least you haven't stuffed everything into a single table; but normally there should be (at least) 3 tables: Students, Courses, and, say, Enrollments. For example, where do you store the course name, its start date and any other data that belongs only to the course itself, and not to any student enrolled in it?

 

Let me add that you shouldn't use the student's registration number as primary key for internal relationships; use an automatically created serial number for that purpose.

 

 

I assume you there is one (1) Score field per CourseRecord (if a field only stores a single thing, it should be named accordingly, to avoid confusion of the kind I just experienced …).

 

Calculation field cRemark, type text! (select at the bottom of the calculation dialog), defined as

Case ( 
  SCORES >= 70 ;
  "Pass" ;
  "Fail" // note that you can use layout formatting options to display this field in uppercase 
)

 

 

This is the same principle, just with a few more cases to consider:

 

Calculation field cGrade, type text! (select at the bottom of the calculation dialog), defined as

Let (
  s = SCORES ;
  Case (
    s >= 70 ; "A" ;
    s >= 60 ; "B" ;
    s >= 50 ; "C" ;
    s >= 40 ; "D" ;
    s >= 30 ; "E" ;
    "F"
  ) 
)

 

Please, I just noticed something using the above. The above is suppose to display an F when the result is less than or equal to 29, but When the score is 4, it gives me E , when it is 5, it gives D,  6 gives C,  7 gives B, while 8 and 9 gives A.  Apart from these few, every other thing works fine. Did I do something wrong? why are those results appearing different?

This topic is 3783 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.