VERIFIED SOLUTION i

How to create Custom SQL in Portrait Dialogue

Product Feature: Plugins / Functions
 
A custom SQL query is used to make available merge data that cannot be found in the customer domain. Merge data should in general be fetched from the domain, if other merge fields are needed, then it is useful to write a custom SQL query. However, note that merging using a custom SQL query will generally slow down the merge process, as the SQL statement has to be executed for every single customer.

Following are the steps to create Custom SQL in a message template:
  • Open Visual Dialog and create any Message Template (Eg. HTML or txt).
  • In the Message Template window, click on Custom SQL from the Design Tab and select use Custom SQL.
  • Write the Custom Sql in the SQL statement (For example, Microsoft Adventureworks 2012 is used)
  • To test the Custom SQL, press Shift + F9 or click on Custom SQL and select Test SQL.
PD_Custom_Sql_Template.PNG

For detailed information about Custom SQL, press F1 on Visual Dialog explorer and search for Custom SQL


 
UPDATED:  September 4, 2017