1 Datasource preparation & import
Best practices for your datasource
- Must contain more than one data column/title (you can disable this behavior in the import preferences if you have a csv with one column only)
- Cannot contain line breaks inside of the data (just at the end of each data record)
- Each flied has to be separated by one of the following characters: semicolon, comma, tab or vertical bar
- Has to be encoded as MacOS Roman, UTF-8 (recommended), UTF-16BE, UTF-16LE, UTF-32BE or UTF-32LE
Import datasource
Drag and drop your CSV file on the CSV icon or select a file by clicking the folder icon. Note: If you have Excel installed and running, you might see an Excel icon instead. You can still drop your csv file [1] on it and it will change to a CSV icon.
Then the settings will pop up. You must select the correct delimiter and encoding or the import will fail. The other options are optional:
Sanitize
With this option turned off, individual fields will be imported exactly like they are found in the .csv file. If you want these fields to be cleaned (surrounding double quotes stripped, characters unescaped, etc.) you can turn this option on.
Backslash as escape
This option allows you to import files where special characters are escaped with a backslash (the separator, newline etc.)
2 Layout preparation & import
Best practices for your layout
- Always expect long data. When preparing layouts for MyDataMerge, you have to add placeholders to text frames. Please make sure that text frames which contain placeholders are big enough to provide enough room for the data you want to merge in.
- Move unneeded stuff to master pages. Instead of keeping all items on the regular pages, move everything that’s does not need to be merged (like decoration, background images…) to the master page. For large databases, this will speed up the process a lot.
- Do not use styling options if every data record has the same styling. Apply styling in your layout document instead.
- Use locally installed fonts instead of auto downloading them from Adobe Cloud. Adobe Fonts can be installed locally as well in your Adobe Creative Cloud app. When loading them online, this can massively slow down the merge process or lead to errors.
- Scale images down. When merging thousands of data records its necessary to scale images down before the merge. No matter if the images are merged or part of the layout. This can save a lot of processing time.
Import
Import Layout
Importing your layout is easy:
Open MyDataMerge, start a new project and drag and drop your .indd file on the INDD area [1] or select the file by clicking the folder button [2]
After adding a datasource you can import both files.
Most common issues that may arise
- If you have missing links or fonts, MyDataMerge will throw an error and ask you to fix this
- If you have no placeholders defined (surrounded by << >>), MyDataMerge will throw an error
- If you have auto-download fonts from Adobe Cloud enabled, MyDataMerge will throw an error – this is because InDesign loads these fonts asynchronously and doesn’t let developers (like us) check the loaded state of these fonts. You can bypass this issue by activating the fonts directly in the cloud (so they are always active)
3 MyDataMerge configuration
Configurations
What are setups and why do i need them?
Once you open a placeholders editor you will see that you can select a replacement type to show MyDataMerge what kind of data you want to inject [1] to that placeholder and you can select a setup [2]. Initially there’s a setup called “Initial setup” you can work with. But you can add as many others as you like.
In the center area (“Add item to ‘Initial setup'”) you can configure the output to be injected in the merge process dynamically. Each setup can have custom style settings (brush icon) and a custom hyperlink setting (chain icon).
By default, only the selected setup is used for the merge process. But setups become really powerful once you add them in a row (if first fails use second then third …) (path icon) or use them based on conditions (“If ‘First Name’ is ‘John’ then use this, otherwise use that).
Add multiple setups
For every placeholder you can add more than one setup.
If you have a well formed database with no missing data, usually one setup is enough. More than one setup will come in handy in situations where this isn’t the case or where you want to apply different styles.
Example:
You have a subject line in a letter where you want to output a salutation and last name e.g. “Dear Forrest” where “Forrest” is the first name and comes from the database and “Dear” is a static text. You can do this easily with a simple setup of your placeholder:
In the below image you can see the setup to output “Dear [First Name]”, a static text for “Dear ” [1] and a dynamic datasource element for the first name [2]. The output can be checked in the preview [3]:
Now imagine you don’t have a first name, then you’d like to output “To whom it may concern” which you can do with a second setup. So we add another setup here and give it an appropriate name [1]:
Then we configure it to output the static text “To whom it may concern”.
Right now, MyDataMerge would output “To whom it may concern” for every data record, because it’s the currently selected setup. To allow multiple setups to be processed you need to enable the process chain [1 + 2] as shown in the image below. Then all setups in the right table [3] will be processed from top down. If first setup fails (e.g. because first name is missing) then use second one and so on.
You can move unused setups to the left table, they will have no effect there. If the last setup in the right table fails, the “Action if last setup fails” will be executed which you can select at the bottom.
Note: You can add more control by adding conditions (on when it should be executed) to each setup.
4 Export
Filetypes
Export to Adobe InDesign® files
If you want to export to Adobe InDesign files go to export > filetype and select the preferred filetype from the dropdown.
Setup custom filenames
To configure dynamic file names go to Export > Filetype and make sure “One document per record” [1] is activated. Then a button “Filenames setup” [2] appears. Click it to configure your filenames.
If you click the “Filenames setup” button you can then select the filetype to setup custom naming. If you e. g. export to PDF files and keep a copy of your InDesign files you can define both the names for the PDF files and the InDesign files. Double click a row and enable it. Then you can configure it like a placeholder.