Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Capture found set

Featured Replies

Hello,

I have been using the "copy all records" method to capure the found set of IDs.

I think i saw another method that avoids the pasteboard but can not for the life of me track it down.

Think it used a List ( ) method.

Anyone point me in the right direction.

best

Stuart

Isn't it today GTRR(FS), which by and large have made the previous method a bygone? ...as well as this:

http://www.kevinfrank.com/download/preserve-and-restore-found-sets.zip

...for the remaining of the tasks??

--sd

Try here?

  • Author

Thank you both. Perfect.

Hey Soren, this is the method that i saw John Mark post and it is certainly the method i have adopted for restoring a found set in a failed find script... but... it does not replace CAPTURING the found set of IDs.

A couple of years ago i added the function of saving the found list as a multi-key under one name... and every user adopted it in a flash.

Comment ... this is a great solution ... i have clients who have 25,000 records in contact lists ... i suppose i should test this out or set a limit on the number that can be saved in relation to the fixed number of reps... or loop the script to store them in chunks...

eg: i = Get ( CalculationRepetitionNumber ) + 500 ...

(ps here is the Link this came from, another level deep ... nearly missed it)

I will have a play...

Thank you both ... these are exactly the methods I was thinking of/looking for.

  • Author

Hi Comment,

Here is a custom function based on your example ... im sure you can probably get rid of "number" and "empty" but im new to recursive functions and could not...

FoundSet = ListIds ( SerialID ; 1 ; "" )

ListIds ( field ; number ; empty )


//Capture a list from the current found set

Let ( capture = empty & "¶" & GetNthRecord ( field ; number ) ; Case ( number = Get ( FoundCount ) ; capture ; ListIds ( field ; number + 1 ; capture )))

im sure you can probably get rid of "number" and "empty" but im new to recursive functions and could not

No you can't! Since you have written:

i have clients who have 25,000 records in contact lists

...sometimes this CF might be thrown at all records in the base.

http://en.wikipedia.org/wiki/Tail_recursion

Checkout the template here:

http://www.filemakerpros.com/GetNthRecordTAIL.zip

Do a cmnd-j ...and see what happens with each of the buttons, only the pink button works with such a whopping set.

--sd

  • Author

Hey Soren,

Great material...

Seems that by a sheer fluke i chose the TAIL method.

It also seems that by a secondary fluke i am one step away from a solution...

a small tweek and a loop script would allow for setting the "result" of the last loop and beginning from record 10000 on the second loop and so on...

mine specifies the start record up rather than the found count down...

great.

I am not sure of what use such huge found sets are, but if I ever needed it I believe I would opt for Copy All Records, with a mechanism for saving and restoring the clipboard.

  • Author

Hi Comment,

The main reason is for storing mailing list history...

Its an easy way of seeing/storing who received publicity info.

These change each mail out ... it also allows you to restore or reuse a previous list.

I have been using the "copy all records" method since v6 but had assumed with all of the new functions one could avoid the pasteboard.

I think the "copy all records" and my "warning pasteboard will get wiped" dialogue is still the most efficient... which is suprising.

It's not that surprising, since it by-passes the Filemaker calc engine (which, I may add, is hopelessly inadequate by today's standards).

Here's one technique for preserving the clipboard contents.

Sometimes isn't the utilization of Applescript not a problem, so you could stay away from the users clipboard this way:

tell application "FileMaker Pro Advanced"

	set savedTextItemDelimiters to AppleScript's text item delimiters

	try

		set AppleScript's text item delimiters to {"¶"}

		set aVar to field 1 of document 1 as string

		set AppleScript's text item delimiters to savedTextItemDelimiters

	on error m number n from f to t partial result p

		set AppleScript's text item delimiters to savedTextItemDelimiters

	end try

	set cell reciever to aVar

end tell

...just remove the outer tell's when embedding! The reason I use the field 1 is that I always have the recordID as first field, you might have chosen it different, so you would need to chase it in the script editor.

--sd

  • Author

Thanks for the input...

Soren unfortunately my solution is xplatform.

I will try them out to test the performance.

best

Stuart

Try http://www.databasepros.com/. John has some free solutions that may be what you are looking for.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.