need help with calculate field

General support questions.
PostPosted: Sun Apr 17, 2005 7:17 am
I have a DB to figure my invoices in my repair business. I have a field which id's my wholesale customers. So parts I use in their repairs will get a discount on parts as opposed to regualr retail customers. My problem is haveing filemaker automatically apply a discount calculation to my invoice to wholesale customers and then charge the retail price(no discount) for retail customers. I also have a calc field to display the discount, but it will apply this calx to ALL my records and not allow me to adjust this calc to apply only to the wholesale customer record. How can I have my db calculate different discount amounts to different customers invoices?
Thanks, Jack
SeedCode Staff
SeedCode Staff
Posts: 2764
Joined: Thu Nov 20, 2003 11:01 am
PostPosted: Sun Apr 17, 2005 10:02 am
I imagine you have a relationship from your invoice to your customer's table and, in customers, have some kind of "flag" for wholesale customers.

If so, your discount calc would be something like this:

InvoiceAmount * if (Customers::WholesaleFlag = 1 ; .10 ; 0 )

This would return a 10% discount for wholesale customers and a $0 discount for regular customers.

Hope that helps.

John
John Sindelar
SeedCode

Return to General Support

Who is online

Users browsing this forum: No registered users and 1 guest

cron
(855) SEEDCODE
[email protected]
Follow us: