Jump to content
Salesforce and other SMB Solutions are coming soon. ×

adding together the contents of the same field from various records


sjd22

Recommended Posts

Hi. I've just joined this forum, so hello folks.

I have created a FM database on a friend's Mac to record invoices that I receive from one employment agency. I have fields for invoice number, staff name, no. of hours and hourly rate, milage, and the cost which is a calculation field.

 

 

Quite often, I have up to five records with the same invoice number and invoice date, but different work dates, hours worked etc as several days may be on one invoice.

 

I want to create a field that adds the end total cost of each field that shares the same invoice number but am struggling.

 

I would also be interested to know if it is possible to make FM stop asking for a "date paid" if an invoice has not been paid. I have a copy of the database with false names etc which I am using to try various things.

 

 

If anybody has any advice, I would be extremely grateful.

 

 

Thanks

Sarah

Cornwall, England

Link to comment
Share on other sites

Check out the fm11 FAQ on self-joins. If you create a global field on the parent side of the relationship with an invoice number entered in this field, the relationship will filter the child table to only include the records of that invoice number. Another field in the parent can calculate the total costs from the child records that match.

 

If you want this to be less dynamic and transitory, consider writing a script that does a find and a sum into a new record in another table.

Link to comment
Share on other sites

This thread is quite old. Please start a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...

Important Information

Terms of Use