Skip to main content
All CollectionsTemplatesTemplate variables
Adding data variables to letter, message and encounter templates
Adding data variables to letter, message and encounter templates
Updated over a week ago

To use data variables, they must be added to a letter, message or encounter template. Data variables automatically prepopulate your letter, message or encounter when you apply your template. They are linked with data from the patient chart, or information on a location or a provider. The available data variables are:

  • Patient Data. For example, you could bring in the patient's age or smoking status.

  • Chart data. For example, you could bring in all of the patient’s surgical history or medication list.

  • Appointment. For example, you could bring in the appointment date.

  • Pronouns make it easier to have pre-configured sentences with correct grammar, for example, I saw “him”. For more information, refer to Patient preferred pronouns.

  • Contacts. For example, Contact Full Name pulls in a letter recipient's name.

Patient and chart variables are similar; patient data variables are linked with a specific data point and chart variables are linked to an entire chart section. For example, a patient data variable can be linked to the field Number of Cigarettes Per Day in the patient’s social history, and only pull in the number of cigarettes, while a chart variable can be linked to Social History and pull in the entire social history.

You must first create your letter, message or encounter template. For more information, refer to Creating letter templates, ​​Creating message templates and Creating or editing encounter templates. Variables can be added anywhere in a letter or message template and to the History, Examination and Assessment sections of the encounter.

Steps

1. Click the area in your template where you want to add the variable.

2. Click Insert Variable.

3. From the list of variables, select the data variable type you want to use. The variable is added to your template. For more information on these variables, refer to Variables for use in letter, message and encounter templates.

📌 Note: Contact variables are only available for letter templates.

4. Patient data variables require additional setup. Click Add Patient Data Variable, and the Add Patient Data Variable window opens.

5. Complete the following fields as required.

⚠️ Important: Do not click outside of the window while editing; the window will close and you will lose your work.

Field

Description

Category, Data Property and Visible Data

Associate the variable to the specific data point in the CHR that you want to pull into your letter, message or encounter.

Category, Data Property and Visible Data are all connected to each other. You must make your selection from top to bottom.

For example:

  • Demographics (such as name, sex or contacts).

  • Identification to pull in health card numbers or other IDs.

  • Social History (only pulls from patient data Social History, not Health Profile Social Hx).

  • Latest lab results pulls from electronic labs in the patient chart.

  • Medical History (such as Problem list).

  • Preventive care, if configured (such as FIT test, Mammogram, COVID-19).

  • User can be Current, Selected or Appointment (such as full name or billing number).

  • Appointment (such as appointment note or service name).

  • Recipient (such as name or email).

Ignore Blank Values

Should be kept as False.

Sentence Prefix

Add text that you want to appear before the variable. For example, the subheading “Alcohol:” can be added before the patient’s Social History > Alcohol data variable.

Sentence Suffix

Add text that you want to appear after the variable. For example, “drinks/week” can be added after the Number of Standard Drinks per Week data variable.

Force lowercase

Most items in patient data are capitalized by default. Force lowercase allows you to remove capitalization when it is better for the word to be lower case.

📌 Note: When the variable is at the beginning of a new paragraph or after an end mark (.), it remains capitalized even if Force lowercase checkbox is selected.

For example, the capitalization for the Smoking > Status variable can be removed so that it can be used in a sentence: “He is a current everyday smoker.” instead of “He is a Current everyday smoker.”.

Separator

Only applicable for patient data where you can have multiple entries, for example Secondary Languages. Allows you to choose a different punctuation between the items, for example “English - French - Spanish”.

Display like a sentence instead of using the above separator

Only applicable for patient data where you can have multiple entries, for example Secondary Languages. Adds commas and “and” to your list for example “English, French and Spanish”.

Automatic punctuation

Only applicable for patient data where you can have multiple entries, for example Secondary Languages. Allows you to separate each item with a comma for example “English, French, Spanish”.

Custom Format

Only applicable for date data fields, such as Date Of Birth. From the list, select the format you want the date or time to appear in. You can also type the format you want, for example YYYY/MM/DD or MM/DD/YY.

6. Click Save.

💡 Tip: Ctrl {command} click to delete a variable.

To remove a variable from a template, you can click beside it and press Backspace {delete}, or hold Ctrl {command} on your keyboard and click the variable.

Updated May 25, 2023

Did this answer your question?