I've got a relation in my profile to a Work Order table, and that Work order table may have for example be like this
 
Profile Email | Profile Work Order ID
john@doe.com | 1234
 
Then I have the Work Order Table like so
WO - ID | Product Name
1234 | Thing 1
1234 | Thing 2
1234 | Thing 3
 
So in my email I want to say something like "Hey John, thanks for buying Thing 1, Thing 2, Thing 3.  We appreciate your business!"
 
Right now I'm trying to go through an Enrichment where I set @productName to that value.  Then I add in that to my code using:
<% var productName = ''; var product = context.targetData.productName; if (productName !== '') { productName = product;} document.write(productName); %>
 
This doesn't seem to be working.  Is it returning an array that I need to break out? Should I be doing it a different way using the WYSWYG tool, and if so where do I look for that?  Any help would be great.  This is driving me insane.