Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn more

View all

Sign in to view all badges

SOLVED

Read and store data from event History - event XML column

Jaspreet_Kaur1
Level 3
Level 3

Hello all,

I need to extract the data from eventXML (ctx type) from the eventHistory schema, but as this column is in the xml format, I am unable to read in the queryDef or query activity.

I need to read some of the fields from this column dynamically and further export them. Unsure the way to extract.

Any help pls?

Have gone to one of the similar issue threads in this forum, but was not clear to me.

Any help will be appreciated.

Thanks,

Jas

@Jean-Serge Biron

1 Accepted Solution
Jean-Serge_Biro
Correct answer by
Community Advisor
Community Advisor

Hi Jaspreet,

When extracting/exporting the file, what kind of file type do you choose ? Xml one ? I don't understand why you get the content.

Regarding how to get specific element/content inside the XML element, sorry I don't know easy way. Eitherr SQL string manipulation (not recommended) or Javascript code manipulating XML element (DOM nodes) (either in the Extract activity/format section or in dedicated JS activity), and of course accurate object elements for specific cases,described in the JSAPI documentation (such as delivery.mailParameters.subject etc).

Regards
JS

View solution in original post

4 Replies
Jean-Serge_Biro
Community Advisor
Community Advisor

Hi Jaspreet,

As in other threads with same subject, please use the Extract activity in a workflow, or the Export template tool (quite the same) to get the xml type fields (mData/memo fields) exported to a file.

BR
JS

Jaspreet_Kaur1
Level 3
Level 3

Thanks Jean,

Tried extracting from the extract activity, but not getting any result.Pasted is the screenshot below, where I want to extract the event XML column data which is in the ctx format. And what if I want to extract some specific field inside that XML. is there any syntax you can share?

1334942_pastedImage_0.png

Jean-Serge_Biro
Correct answer by
Community Advisor
Community Advisor

Hi Jaspreet,

When extracting/exporting the file, what kind of file type do you choose ? Xml one ? I don't understand why you get the content.

Regarding how to get specific element/content inside the XML element, sorry I don't know easy way. Eitherr SQL string manipulation (not recommended) or Javascript code manipulating XML element (DOM nodes) (either in the Extract activity/format section or in dedicated JS activity), and of course accurate object elements for specific cases,described in the JSAPI documentation (such as delivery.mailParameters.subject etc).

Regards
JS

View solution in original post

jasonw30638826
Level 4
Level 4

Hi Jaspreet,

I have the same issue. I am not able to extract to XLM element to CSV format. It would be the best if I can to extract some specific field inside that XML. Have you figured out a way to archive this?

Thanks,

Jason