Example Workflow: Automated Database Publishing
Successful businesses, large and small, rely on databases to organize and store information vital to their operations. And it is common practice to use this stored data to create reports, catalogs, and other documents used in marketing, sales, and management of products. For businesses looking for speed, accuracy, and scalability in their operations, automation is the essential element of their success.
The following workflow is an example of how stored data is quickly and accurately poured into print-layout templates using Automator, FileMaker Pro, and Adobe InDesign. Note that the principles demonstrated here remain functional regardless of the scale of the project or operation, or the applications used.
Building a Catalog: The Catalog
This workflow will construct a simple two-page product catalog using text and images from a FileMaker Pro database, placed into an Adobe InDesign template.
Each product will be represented in the catalog by an image placed above formatted text describing the product and listing its SKU number, manufacturer, and price.
Building a Catalog: The Database
The data used to construct the catolog is kept in a FileMaker Pro database. Each record in the database contains fields for the product name, manufacturer, price, description, and SKU. The SKU of a product is a number used to identify the product, with each SKU being a unique number not shared by any other products. In addition, each record contains a summary field (below product image) that displays the text of other fields, reordered as it would appear in a catalog.
Building a Catalog: The Template
Each spread in the InDesign document contains a grid of frames arranged in alternating rows of picture and text frames. Each picture frame (the red ones with the cross guides in them) will be paired to a corresponding text frame below it.
In order for automation to be possible, each text and picture frame in the layout document must be named or tagged with a unique identifier that corresponds to a particular record in the source database. In this example, the unique identifier is the product SKU number, which will be used by Automator to locate the data to be placed in the tagged text and picture frames.
In Adobe InDesign, frames can be tagged using the Script Label palette which is accessed from the Windows > Automation sub-menu. Simply select the frames to be tagged and enter the tag text in the Script Label palette. To view a frame's tag, click on it in the layout and its tag will appear in the palette.
NOTE: the InDesign template included with the demo files you installed (see BEFORE YOU BEGIN at the top right of this page), has been pre-tagged to match the example database records.
Building a Catalog: The Workflow
The first step in creating this example workflow is to open the InDesign template file and the FileMaker Pro database located in the Automator Publishing Demo folder in the FM-Automator Publishing Demo folder that was placed on the desktop when you ran the FM-Automator Publishing Demo Installer application.
Once the template and database files are opened, launch the Automator application, found in the Applications folder. In the forthcoming Automator window, click on the FileMaker Pro application library to reveal the actions for that library. In the Actions list, select the "Publish to InDesign Text Frames" action.
NOTE: if you haven't installed the FileMaker Pro Action bundle (see top right of this page), you will only see two actions. That's fine, as you'll only need those two for this workflow example.
To add this action to the workflow, drag it from the Actions list to the workflow area on the rightside of the Automator window. The Action View containing the parameters for this action will be displayed.
Note that the two lists are automatically updated to display the name of the fields in the currently open FileMaker Pro database. Your selections in these lists will determine how the data in the database is to be published to the InDesign template.
The list on the left is used to identify to the action which field in the database contains the unique identifier that corresponds to the tags of the text frames in the InDesign layout. In this example, the "SKU" field contains the unique identifier, so select it in the list on the left.
The list on the right side of the Action View is used to identify those fields whose contents are to be placed in the corresponding text frames in the InDesign layout. This list view allows you to select multiple fields by selecting the checkbox next to each field name, and to re-order the fields in the correct order for export. For this example, simply select the checkbox next to the field name titled "Summary."
Next, select the checkbox at the bottom right of the Action View titled "Apple Stylesheet" to enable the popup menu containing a list of the stylesheets in the InDesign document. Choose the stylesheet named "Ad Text 01" from the popup menu to indicate to the action to apply the chosen stylesheet to the first paragraph of the placed text.
When the workflow is executed, the action will apply the stylesheet indicated as the Next Style of the stylesheet of the first paragraph to the second paragraph, and so on until it has formatted every paragraph in the placed text.
The next action in the workflow will import and format the product images into the InDesign layout. Select the "Publish to InDesign Pict Frames" action from the Action List and drag it to the end of the workflow and release.
As with the previous action, the list on the left side of the Action View will indicate the database field that contains the unique identifier. Select the field name titled "SKU" in the list.
The list on the right side of the Action View will be used to indicate to the action which database field contains the image path or location. Select the field name titled "Product Image" from the list.
NOTE: the Product Image field in the FileMaker Pro database were set to only store a reference to the image file on disk, not the actual image data itself.
The final step in the workflow creation is to select the checkbox at the bottom right of the Action View titled "Auto-adjust image." If selected, the action will size each image so that it fits properly in its containing picture frame.
Building a Catalog: Run the Workflow
To execute the workflow, click the "Run" button at the top right of the Automator window.
- The action asks InDesign for a list of references to the text and graphic frames in the open template that have a tag assigned to them.
- The action then iterates the returned list and extracts the tag for each page item in the list of found page items.
- If a page item is a text frame, the action uses the extracted tag to locate a record in the FileMaker Pro database whose unique identifer cell contains the extracted tag.
- The action then extracts the contents of the record cells chosen by the user in the action view, and inserts their data into the targeted text frame in the InDesign template. The inserted text is then formatted using any stylesheet chosen by the user.
- If a page item is a graphic frame, the action uses its tag to locate a record in the FileMaker Pro database whose unique identifer cell contains the extracted tag.
- The action gets the path to the image file from the uer chosen picture cell in the matching FileMaker Pro record, then imports the image into the target graphic frame and sizes the image to fit the frame appropriately.
Automator will play a chime when the workflow has completed and the catlog created.
This example workflow is a small example of the power of automation and Automator. If you want to learn more about Automator, click the Examples tab at the top of this page. To learn how to create your own actions, click the Developer tab.