Database Reference
In-Depth Information
error. Reverting avoids this error since nothing is being saved. Moral of the story: Try to commit a
record
only
when necessary.
Copy All Records/Requests
While
Copy Record/Request
copies the entire
current
record, its brother—
Copy All Re-
cords/Requests
—copies
every
field on the current layout for every record in the found set.
Each individual record is added to the Clipboard in the same format as the
Copy Record/
Request
command produces, with one record on each line. Each record is separated by a
paragraph character.
Suppose, for example, you want to get all the Invoice IDs for a particular customer and put
them in an email to a coworker. Or perhaps you're compiling a list of all the Zip codes in
Phoenix where you have customers. Using
Copy All Records/Requests
, you can do this
job with ease.
The trick is to create a
new
layout that has only one field on it. For example, make a new lay-
out with just the Invoice ID field, or just the Zip Code field. Write a script that switches to
this layout and then runs the
Copy All Records/Requests
command to get a simple list of
values on the Clipboard.
Working with Portals
FileMaker has a script step specifically designed to go to a certain portal row. Why would
you want to do that? First, when you use the
Go to Field
script step to target a field in a
portal, it goes to the
first
portal row, which may not be the one you need. If you want to put
people in the field on a
different
row, you need to go to that row first.
When you use data from a related field, or put data in a related field, and you have
multiple
related records, FileMaker grabs the value from the
first
record. If you want to tell FileMaker
to work with a different related record instead, then use a portal, and go to the right row. See
the box on
Beware the Portal
for tips (and a warning) on working with portals.
Go to Portal Row
The
Go to Portal Row
script step works a lot like the
Go to Record/Request/Page
step.
You can go to the First, Last, Previous, or Next portal row, or specify the row
number
with a
calculation. It even has an “Exit after last” option to help when looping through portal rows.
This step includes an option you can use to make what's happening onscreen a little more ob-
vious to people: “Select entire contents.” When you turn this checkbox on, FileMaker high-