Database Reference
In-Depth Information
Perhaps most important, you can add new fields to the shadow table. Specifically, you can
add unstored or global calculation fields and summary fields. Neither of these field types
work with SQL databases, but both are super-important to FileMaker developers. By adding
them to the shadow table, you can treat the SQL tables a little more like normal FileMaker
tables. For example, you can add summary fields so you can do complex reporting on the
SQL data, or add a calculation field to show a subtotal on a FileMaker layout.
TIP
Remember, the fields you add to the shadow table aren't in the real table. They live only in
FileMaker.
Finally, if the underlying SQL table changes in some way (perhaps the database administrat-
or added a new column you're particularly interested in seeing), click Sync at the top of the
window. This button tells FileMaker to go back to the SQL database and find out if any
columns have been added, removed, or adjusted.
Syncing has nothing to do with the data in the database, though. FileMaker always interacts
with the SQL database directly to show up-to-the-moment data as you perform searches or
make changes. The Sync button synchronizes only the field definitions from the SQL table.
Using SQL Tables
There's no secret to using a SQL table—it works just like any other FileMaker table. You can
create a new layout to show records from the SQL table. You can view those records in List
view, Form view, or Table view. You can write scripts that loop through SQL records, or use
the Go to Related Record script step to find the records associated with a particular customer.
Everything you know about FileMaker still applies. But keep a few points in mind as you de-
velop your database around SQL tables:
▪ You can configure access to a SQL table by using privilege sets just like any other
FileMaker table. But a privilege set can't overrule the underlying SQL database. If the
user name and password you're using to connect to the SQL database don't provide per-
mission to delete records, FileMaker can't delete them, no matter how hard you try.
FileMaker does its best to give meaningful error messages in such situations.
▪ Speaking of error messages, since SQL databases are more restrictive than FileMaker,
you may see error messages in places you wouldn't normally expect. For example, a
Name field might be limited to 30 characters. If you try to enter more than that,
FileMaker lets you, but you can't then commit the record. It would be nice if FileMaker
Search WWH ::




Custom Search