Inserting information into a worktable | Community
Skip to main content
adamk81589338
Level 2
Jul 18, 2018 6:15 PM UTC
Solved

Inserting information into a worktable

I have a workflow that takes a group of recipients and spilts them into subsets, emails those recipients, and saves the temporary table with a ListUpdate so that we can associate the results of the tracking with individual segment codes. However, I need to save additional information during the workflow.

Specifically I need to associate more data per segment code that is not consistent between sends, (external_system_ids, specific variation codes, and a pre-personalized subject line). Is there any simple way to enrich the temporary table by INSERTING data directly into it from some bit of code provided from within the workflow?

After the Split, I would prefer to be able to turn this temporary worktable schema:

into this:

I would like to refrain from requiring some pre-created external table, since if that was required it would need to be recreated before every new campaign.

Best case scenario would be something that could be saved into a specific templated workflow and then adjusted at a few points for the specific campaign.

TDRL: Is it possible to insert campaign specific information directly into a temporary worktable from the workflow? (such as from the JavaScript or with SQL)

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Adhiyan
AdhiyanAccepted solution
Employee
Jul 20, 2018 12:23 PM UTC

Hi Adam,

After you create the column by enrichment, you can write the data there using an expression or function using the advanced selection field.

Alternately you can also use a JS to write that into the temp table in the columns created.

xtk.session.Write(<query _operation="insert" _key="@id" col1="" col2="" xtkschema="temp:enrichment"/>);

Regards,
Adhiyan

3 replies

Adhiyan
AdhiyanAccepted solution
Employee
Jul 20, 2018 12:23 PM UTC

Hi Adam,

After you create the column by enrichment, you can write the data there using an expression or function using the advanced selection field.

Alternately you can also use a JS to write that into the temp table in the columns created.

xtk.session.Write(<query _operation="insert" _key="@id" col1="" col2="" xtkschema="temp:enrichment"/>);

Regards,
Adhiyan

Translate
adamk81589338
Level 2
Jul 19, 2018 2:32 PM UTC

Thanks, I was looking at enrichment was wasn't entirely sure if it would do what I wanted. To clarify:

We can add new -empty- columns during the enrichment process, correct?

After adding the columns during the enrichment process. How do I feed data into the worktable? The best case for me would be to be able to feed from the delivery itself so I can enter data at the recipient level as its being evaluated. However, any suggestions here, or short examples would be very helpful.

Translate
vraghav
Employee
Jul 19, 2018 12:51 AM UTC

Hi adamk81589338 ,

You can use an Enrichment activity right after the Split and then Add new columns to the transition to feed data of choice.

Regards,
Vipul

Translate