eSBee Posted March 14, 2005 Author Posted March 14, 2005 Hello all I have a customer file and an estimate file. I want to write a script to find the last estimate for a customer based on a value within a value list. This is my first time writing a script and I can't see how to set the value for a value list field. The relationship is 1:m in that a customer can have a number of estimates. I'm using FMP v7.3 Many thanks in advance for any help you can give. eSBee
eSBee Posted March 14, 2005 Posted March 14, 2005 Hello all I have a customer file and an estimate file. I want to write a script to find the last estimate for a customer based on a value within a value list. This is my first time writing a script and I can't see how to set the value for a value list field. The relationship is 1:m in that a customer can have a number of estimates. I'm using FMP v7.3 Many thanks in advance for any help you can give. eSBee
eSBee Posted March 14, 2005 Author Posted March 14, 2005 Hello all I have a customer file and an estimate file. I want to write a script to find the last estimate for a customer based on a value within a value list. This is my first time writing a script and I can't see how to set the value for a value list field. The relationship is 1:m in that a customer can have a number of estimates. I'm using FMP v7.3 Many thanks in advance for any help you can give. eSBee
aaa Posted March 14, 2005 Posted March 14, 2005 Create relation from Customer to estimate. Then use Go To RR script step and last estimate will be in the last record.
aaa Posted March 14, 2005 Posted March 14, 2005 Create relation from Customer to estimate. Then use Go To RR script step and last estimate will be in the last record.
aaa Posted March 14, 2005 Posted March 14, 2005 Create relation from Customer to estimate. Then use Go To RR script step and last estimate will be in the last record.
eSBee Posted March 14, 2005 Author Posted March 14, 2005 Sorry, my explanation was naff. I want to find all customers who has had estimates which have been given a status of "Archived". Due to some customers having more than one estimate, I need to view the last estimate produced. The status field is a popup menu taking its values from the status value list. I hope that better explains it. Many thanks for your quick response.
eSBee Posted March 14, 2005 Author Posted March 14, 2005 Sorry, my explanation was naff. I want to find all customers who has had estimates which have been given a status of "Archived". Due to some customers having more than one estimate, I need to view the last estimate produced. The status field is a popup menu taking its values from the status value list. I hope that better explains it. Many thanks for your quick response.
eSBee Posted March 14, 2005 Author Posted March 14, 2005 Sorry, my explanation was naff. I want to find all customers who has had estimates which have been given a status of "Archived". Due to some customers having more than one estimate, I need to view the last estimate produced. The status field is a popup menu taking its values from the status value list. I hope that better explains it. Many thanks for your quick response.
Ugo DI LUCA Posted March 14, 2005 Posted March 14, 2005 Hi, If Status is an indexed field, then a double equijoin matching Customer and Status involving CustomerID and gStatus (a global for example) on the starting side of your relationship should just reveal all estimates which status match the content of your gStatus field. Grabbing the first (or last) one is just a matter of how the relationship is sorted as a related field would target the first related record (based on the sort order). Is that clear ?
Ugo DI LUCA Posted March 14, 2005 Posted March 14, 2005 Hi, If Status is an indexed field, then a double equijoin matching Customer and Status involving CustomerID and gStatus (a global for example) on the starting side of your relationship should just reveal all estimates which status match the content of your gStatus field. Grabbing the first (or last) one is just a matter of how the relationship is sorted as a related field would target the first related record (based on the sort order). Is that clear ?
Ugo DI LUCA Posted March 14, 2005 Posted March 14, 2005 Hi, If Status is an indexed field, then a double equijoin matching Customer and Status involving CustomerID and gStatus (a global for example) on the starting side of your relationship should just reveal all estimates which status match the content of your gStatus field. Grabbing the first (or last) one is just a matter of how the relationship is sorted as a related field would target the first related record (based on the sort order). Is that clear ?
eSBee Posted March 14, 2005 Author Posted March 14, 2005 I'm not sure that I do. I can create an equijoin from customer to estimate using CustomerID but I don't understand the gStatus field. Could you please give me an example of what you mean? Like I said, I'm quite new at FileMaker so simple explanations, preferably with examples would be helpful. Sorry to be a pain. Many thanks eSBee
eSBee Posted March 14, 2005 Author Posted March 14, 2005 I'm not sure that I do. I can create an equijoin from customer to estimate using CustomerID but I don't understand the gStatus field. Could you please give me an example of what you mean? Like I said, I'm quite new at FileMaker so simple explanations, preferably with examples would be helpful. Sorry to be a pain. Many thanks eSBee
eSBee Posted March 14, 2005 Author Posted March 14, 2005 I'm not sure that I do. I can create an equijoin from customer to estimate using CustomerID but I don't understand the gStatus field. Could you please give me an example of what you mean? Like I said, I'm quite new at FileMaker so simple explanations, preferably with examples would be helpful. Sorry to be a pain. Many thanks eSBee
Recommended Posts
This topic is 7533 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 accountSign in
Already have an account? Sign in here.
Sign In Now