Calculating Wins and Loses

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

Recommended Posts

• Newbies

Hi there,

I am extremely new to filemaker but trying to learn on my own.

I am creating a betting pool with my friends for this upcoming football season.  I want to calcuate how many picks a person got right based on calculating their weekly record and then calculating their overall record.  I know this is simple but I can't seem to figure it out.

The fields I want to evaluate in my layout "week 1" are:

Winner - Team that covered the spread

Scott - What team I picked that week

The first thing I did was create a calculation field(Scott Weekly TrueorFals) with  If(Week 1::Winner = Week 1::Scott; 1; 0).  This told me if I picked the correct team I got a 1 and if I did not I got a 0.

Then from there I want to calculate how many 1's (wins) and then how many 0's(loses) there are for the week.  This is the part im stuck on.

Share on other sites

You're on the right track, but missing one part..are you only doing one game per week or multiple games per week?(or something like that?)

Anyway, you want to look at Summary fields or the calculation called Sum.

If you clue us into your database structure(tables/links) with a little more detail we could better advise on which function to use to calculate your wins.

You're on the right track, but missing one part..are you only doing one game per week or multiple games per week?(or something like that?)

Anyway, you want to look at Summary fields or the calculation called Sum.

If you clue us into your database structure(tables/links) with a little more detail we could better advise on which function to use to calculate your wins.

Share on other sites

• Newbies

I've attached a picture of the fields I am using and hope that helps.Â  Five of my friends and I will be picking all 15 games a week. Whoever picked the most right games for that week is the winner.Â  The "Scott Weekly Wins" is the field I want to calculate how many win's(1's) I got for that week in the "Scott Weekly TrueofFals" Field.Â  I hope I am making sense.

Â

Share on other sites

I want to calculate how many win's(1's) I got for that week in the "Scott Weekly TrueofFals" Field.

You can define a summary field as Total of [scott Weekly TrueofFals]. This will show the sum of the values in the field for the current found set - so to get the number of "how many win's(1's) I got for that week", you will need to find the games for that week first (assuming you keep a history of all games).

This is of course a totally wrong structure to have, and if this were anything more serious than a friendly betting pool, I would encourage you strongly to ditch it and start from scratch with a proper relational structure.

Share on other sites

I am creating a betting pool with my friends for this upcoming football season.

Â

Â

The way you've set this up, you may as well use Excel; if you want to do it more convenient and in the FileMaker way, you'd need something like this:

Â

Â

Which is the product of tables that store Seasons, Teams, Matchdays, Matches, Betters (People)Â and Bets, plus some join tables, and the scripts to automatically generate slots for matches and bets. (For 15 games per week, one should probably ditch the filtered portal method for the bets display and use â¦ well, something elseÂ  Â )

Â

This was originally done for a soccer league table, and adapted for the screenshot with some NFL team names. I'd have no problem giving you the template, but the file was built with FM13, and I really don't want to re-build it in FM11.Â

Share on other sites

tables that store Seasons, Teams, Matchdays, Matches, Betters (People) and Bets, plus some join tables

Let's not get carried away: Games, Members and Bets should be quite adequate for starters. Teams would make a nice addition. Can't  see the need for Matchdays, dubious about Seasons.

Share on other sites

My guess it's part of the "Tables are cheap" "Fields are expensive" mantra. I've found myself using more tables to keep the field list thin in each table ( obviously only as necessary and practical for the solution ).

I have also been warehousing data as a summarized count/total in its own separate table. And just updating it as transactions happen. From a performance stand point, it's often performed better over a WAN that way. I so rarely use Summary fields. And even calculation fields much less than I used to. With that the Season and/or Matchdays table comes in handy. Though I am not sure I would use both.

If you are only doing a local file to track and it's not going to be deployed over a WAN, I suppose it's a matter of preference for a personal project like this.

Let's not get carried away: Games, Members and Bets should be quite adequate for starters. Teams would make a nice addition. Can't  see the need for Matchdays, dubious about Seasons.

Share on other sites

My guess it's part of the "Tables are cheap" "Fields are expensive" mantra.

I am afraid I don't understand the context of this bartering. The Matchdays table seems redundant to me since I cannot see what information it can hold other than a bunch of dates. The same date, presumably, is used as the matchfield between Games and Matchdays - so no fields are eliminated (if that matters).

Share on other sites

• Newbies

The way you've set this up, you may as well use Excel; if you want to do it more convenient and in the FileMaker way, you'd need something like this:

Which is the product of tables that store Seasons, Teams, Matchdays, Matches, Betters (People) and Bets, plus some join tables, and the scripts to automatically generate slots for matches and bets. (For 15 games per week, one should probably ditch the filtered portal method for the bets display and use … well, something else   )

This was originally done for a soccer league table, and adapted for the screenshot with some NFL team names. I'd have no problem giving you the template, but the file was built with FM13, and I really don't want to re-build it in FM11.

Ya, I have set it up in excel because thats all I really know how to do when it comes to organzing the data.  I would love to be able to enter it into filemaker but I've never worked directly with filemaker before.

I really like the way you have this set up.  I have Filemaker 12 at home.  Would your template work on that?

Share on other sites

hmmmm...I read Matchdays as the summary of a series of games...  A week in football, for instance. Not all games are played on the same day. Maybe rolling the week's data up into a single record in the Matchday. I don't know soccer well enough to know what benefit it would have in that schedule.

I am afraid I don't understand the context of this bartering. The Matchdays table seems redundant to me since I cannot see what information it can hold other than a bunch of dates. The same date, presumably, is used as the matchfield between Games and Matchdays - so no fields are eliminated (if that matters).

Share on other sites

I have Filemaker 12 at home.  Would your template work on that?

Yes, after I converted the few FM13-only features to FM12, and have some other things shuffled around. Let me do that, then I'll post the file.

Share on other sites

I have Filemaker 12 at home.  Would your template work on that?

See attached file.

LeagueMatchesAndBets_eos.fmp12.zip

Share on other sites

• Newbies

See attached file.

this is awesome thank you so much.

Share on other sites

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

Create an account

Register a new account

• Similar Content

• I know the solution is probably very easy but it escapes me. I got this database, which I use to create invoices, year after year, I created a report page where with a neat summary field I get the "lifetime revenues", "lifetime general expenses", "lifetime total taxes" and "lifetime total invoices number", which is handy, but I need to have the same data broken down by year, and I can't figure out how to achieve that.
In another post I have been suggested to consolidate the three tables I had (Invoices 2018, Invoices 2019 and Invoices 2020) into a single table (Invoices) and then use a "subsummary" which would give me the data I want based on how I sort the records but I am not sure how to use subsummaries nor I am sure I want something where I have to multiple click to re-order records to get data one at a time; I'd rather prefer a report where a calculation of some sort would make a sum of the total revenue of my invoice records broken down by year, as I exemplified in the database I'm attaching, is that possible in an easy, possibly not involving complicated subsummaries way?
I'm beginning to get desperate on the subject, please have mercy.
Invoices Demo.fmp12

• I have a parent table with 3 child tables.  In the child table, there can be many related fields.  I need to export only one row of data for each record in the parent table.  This would require that a new column be created for each of the many values related in the parent to the child.

For Instance:
Noah Justin has 3 Email Address NJ@Test.com, NJ2@Test.com, and NJ3@Test.com

When I do an Excel Export from FM I get
Column 1 .       Column 2
Noah Justin    NJ@Test.com
NJ2@Test.com
NJ3@Test.com

I need:
Column 1 .     Column 2 .        Column 3 .          Column 4
Noah Justin  NJ@Test.com  NJ2@Test.com  NJ3@Test.com

I'm sure it's pretty common and there is an easy solution to this.

TIA
• By Monarch
Hi everyone!
I have a text field, with each sentence separated by ¶ .
I would like to create buttons for each line in this field, so that I can copy each line individually (and paste manually in different application for example)
I assume that it's easy to do in calculation with GetValue, and make a script using Get (ScriptParameter) = line number in that field, for each button. ( I ll need only 7-10 lines max).
1. I can't figure out what script function I need to use to make a selective copy...
2. If one of the option is Set Selection function - how would it work in my case?
Thank you!
• By TaiChi56
I have always developed with FileMaker for windows. I have bought myself a MacBook Air and love it. So now I am using FileMaker 16 Pro advance for MAC. I know that MAC does not label their directories like windows does. So I am having problems figuring out to get the right coding to access my photos. I have a folder called "Photos" that reside on the C: drive in windows. Then I reference that folder so pictures will populate automatically when I put in a record. Here is what I have on the windows fileMaker:
ImagePath:
Let ( [ // Transform the contents of a container field named Images to text ImageRef = GetAsText ( ImagePath); Photos = Position ( ImageRef; "/"; 1; PatternCount ( ImageRef; "/")) ]; Middle ( ImageRef; Photos + 1; Length ( ImageRef ) - Photos ) ) images:
"imagewin:/C:/Photos/" & Film::title & ".jpg" Then I go into Import folder and point to the folder all the photos are in. The problem I have now is how to point to that folder in "imagewin", is their an alternative called imagemac, then I could put in Macintosh HD/Users/patricks/Documents.  The folder is in the Document folder, called Photos. Thank you for any help.

• FileMaker Coaches' Corner - Tip 11 - Improve Performance - FileMaker - FileMaker Experts
https://youtu.be/5D2qoA_S7u8
Get up to speed with the FileMaker Pro 17 Video Training Course!
Top Rated Course by FileMaker Expert, Richard Carlton.
http://learningfilemaker.com/fmpro16.php
Experience Richard's dynamic and exciting teaching format, while learning both basic, intermediate, and advanced FileMaker development skills. With 27 years of FileMaker experience and a long time speaker at FileMaker's Developer Conference ,Richard will teach you all the ins and outs of building FileMaker Solutions.  The course is 50 hours of video content!
Richard has been involved with the FileMaker platform since 1990 and has grown RCC into one of the largest top tier FileMaker consultancies worldwide.
Richard works closely with RCC's staff: a team of 28 FileMaker
developers and supporting web designers. He has offices in California, Nevada, and Texas.

Richard has been a frequent speaker at the FileMaker Developers Conference on a variety of topics involving
FileMaker for Startups and Entrepreneurs, and client server integration.

Richard is the Product Manager for FM Starting Point, the popular and most downloaded free FileMaker CRM Starter Solution.

Richard won 2015 Excellence Award from FileMaker Inc (Apple Inc) for outstanding video and product creation, leading to business development.

RCC and LearningFileMaker.com are headquartered in Santa Clara, CA.

http://www.rcconsulting.com/
If you want to explore building I.O.S apps for I Phone or I Pad and deploying those out to the Apple App Store.

Here is a video introduction to our iOS App Training https://www.youtube.com/watch?v=cVxQe_yAshw
For More Free FileMaker Videos Check out Http://www.filemakerfree.com
Visit http://www.learningfilemaker.com for all facets of FileMaker Award Winning Video Training.

Please Comment, Like & Share All of Our Videos.

Feel Free to Embed any of Our Videos on Your Blog or Website.

Filemaker Pro 17 Training Videos
FileMaker 17 Videos
Filemaker Pro 17 Video Course
#FileMakerVideos
#FileMakerTrainingVideos
#WhatisFilemaker17
#FilemakerPro17Training
#Filemaker17VideoTutorial
#FilemakerPro17Videos
#FileMakerCoaches'CornerTip11
×
×
• Create New...