add number

add number

am 27.01.2008 09:01:00 von danielsloan

How can I put auto numbers on filemaker pro?

Example
Field: number
point1 2-8
point2 4-3
point3 1-0

Total 7-11 not 81


Daniel R. Sloan
Email: dannysloan@comcast.net

Re: add number

am 27.01.2008 10:01:35 von Remi-Noel Menegaux

You parse the points in numbers, using 'Middle' and 'Summary'.
I send you privately an example I made for you.
Remi-Noel


"Daniel R. Sloan" a écrit dans le message de
news:HNSdnTqore1DqgHanZ2dnUVZ_o-mnZ2d@comcast.com...
> How can I put auto numbers on filemaker pro?
>
> Example
> Field: number
> point1 2-8
> point2 4-3
> point3 1-0
>
> Total 7-11 not 81
>
>
> Daniel R. Sloan
> Email: dannysloan@comcast.net
>
>
>

Re: add number

am 27.01.2008 22:58:52 von Helpful Harry

In article , "Daniel R.
Sloan" wrote:

> How can I put auto numbers on filemaker pro?
>
> Example
> Field: number
> point1 2-8
> point2 4-3
> point3 1-0
>
> Total 7-11 not 81

If you want to total the two numbers separate, then the best way is to
store them as separate fields. So instead of you example above, you
should probably change the database to store records as:

Field Number1 Number2
point1 2 8
point2 4 3
point3 1 0

Total 7 11

You can of course display / print those two separate fields to look
however you want them to.



If you want to stick with storing the numbers in one field as "2-8",
then you will have to create two extra Calculation fields that split
this format into the two separate fields so they can be easily
totalled.

This can be done by finding where the "-" charater is with the Position
function and then using the Left and Right functions to grab the digits
from either side of it.
eg.
Number1 Calculation, Number Result, Unstored
= Left(NumberField, Position(NumberField, "-", 1, 1) - 1)

This takes all the characters on the left side of the "-" character
(ie. all the digits fomr 1 to the position of the "-" minus 1, since
we don't want the "-" itself).


Number2 Calculation, Number Result, Unstored
= Right(NumberField, Length(NumberField) -
Position(NumberField, "-", 1, 1))

This takes all the characters on the right side of the "-" character
(ie. all the digits after removing everything up to, and including, the
position of the "-" character).

You can then use the original field for display / print and data entry,
but use these two Calculation fields for the totalling and any other
mathematical needs.


Helpful Harry
Hopefully helping harassed humans happily handle handiwork hardships ;o)