March 6, 200322 yr I have a database with a field country. It is a popup menu field with this option: USA, Chile, France, Other I need to make a script that find all record's than match country=USA or country=Chile at once. How can I do it ??
March 6, 200322 yr Enter the Find Mode, select USA in the country field, select a new request (CTRL N or Apple N), select Chile in the country field. Now execute the find. You should now see all records from Chile and the USA. Now, create a new script (Find Chile and USA) and edit it until it contains only the Perform Find[Restore] step. Thats it. Your new script will only find USA and Chile records.
March 6, 200322 yr Author Thanks a lot, but I have to doit for any combination of data, for that reason I'm thinking to doit with 2 auxiliary field's, let say country1 and country2. This way the user can suplies this to field a the script must find all the record wheare the "country=country1 or country=country2". This is good for me, but how can I doit with a script : (sorry about my language I'm a spanich spoken)
March 6, 200322 yr In that case, II would use a self-relationship using a global field g_country. This global could be set in the layout. Your script therefore could be a one line script : Go to related records (SelfjoinonCountry).
March 6, 200322 yr Author ok, works good when I'm looking for one country but how you doit with two coutry's? Let say Chile or USA
March 6, 200322 yr Put a single carriage return into the field. This makes 2 indexed value to be searched. Chile USA If you have to do it by script, Chile & "PP" & USA where PP stands for Carriage return. Also called Multikey match...
March 6, 200322 yr Author What I dit is: I have a filed country and a field g_country. I made the self relation country->g-country If I put USA at g-country field and I run the script all the USA records apear, because I have only one country to find. But I have to find for 2 countries, how can I tell to filemaker to show me record's weare "country=USA" and "country=Chile" : g-country accept only one of them at the same time.
March 6, 200322 yr Set relationship g_country::country. Enter USA + carriage return CHILE Then script your Go to related records. It sure works.
March 6, 200322 yr Author Thank's a a lot, it work's great. What I finaly did was: I have a field country, a field a_country, a field b_country and a calculation field g_country g_country=a_country & "
March 6, 200322 yr OK. I've had a read of this and I have attached a file which contains a sample of 2 ways to do this. One is a Scripted Find, and the other is a Relationship Method. Country Tester v2.fp5.zip
March 6, 200322 yr Vaughan, Well there is this rumor that there is something else going on militarily in the world right now but the "relationship" method tweaked the interest gene, as I hadn't used it like that before.
March 8, 200322 yr Author I have the zip file but the FileMaker File is pasword protected. It is Working good but I can't see how you dit it
Create an account or sign in to comment