I have written before about E-mail Templates in Sage CRM. See "Fields Available in Email Templates".
In one of the comments added to that article, I mentioned that Custom Entities only use the view vSearchListUser. This is not the whole story as that implies that only fields contained in that view are included in the template. That is clearly not the case as we can see from the screenshot below.
The image above shows that fields from the custom entity called 'Event' are available along with fields from the user table drawn from the view vSearchListUser.
In fact we can reference any field from any table that is in context when the template is used. For example in my system I created the custom entity as a child of the Person, Company and Opportunity records.
You can see those relationships within the fields of the custom entity above.
Although we saw that only fields from the custom entity and the user table can be picked from the drop downlist we can nevertheless include fields from other tables just by typing the merge codes (#xxxx_fieldname#) we need.
Below is a screen image that shows a template that has been created that has includes fields from the Company, Person and Opportunity tables. I've also included a reference to an address field which will not be merged.
These will be merged:
Person details: #pers_firstname# #pers_lastname#
Company Details: #comp_name#
Oppo Details: #oppo_description#
Event details: #even_name#
User details: #user_logon#
This will not be merged:
Address Details: #addr_postcode#
When the Template is referenced by a user within the context of the Custom Entity, they will also be in the context of the Company, Person and Opportunity so those fields are merged. But the address information is NOT available.