Dynamics 365 for Marketing – Copy Segment

When working with Dynamics 365 for Marketing it isn’t (currently) possible to copy a segment. If you want to create a new segment based on an existing one you need to manually create the segment from scratch. In this post I will explain how to create a copy segment feature.

Hopefully one day Microsoft will add a “Save As” feature to segments! Until then this workaround might help ….

Step One – Create a workflow

The first step is to create a workflow, I have called mine “Copy Segment Process”.

Notice that the entity name is segment.

Step Two – Set the properties on your workflow

My workflow is going to be an on-demand workflow. So select that option.

Also you will probably want everyone to be able to run this, so change the scope to organisation.

By default workflows will run when records are created. I don’t want that to happen so untick the “record is created” option.

Step Three – Add steps

Next we’ll add the steps need on the workflow.

First of all I decided to add a condition, why? Well I wanted to reduce the chance of users creating loads of duplicate segments. So to reduce the chance of that happening I decided to check that the name of the segment doesn’t contain “(COPY)”. More on the segment name in a second!

Next I added a create entity step, and the entity I want to create is a segment.

I now need to click the set properties button to define what properties I’ll have on my copied segment.

My name field is set to the name of the segment. Notice that I have added “(COPY)” after the name. This will actually create an invalid segment name! I have done this to force the user to rename the segment before making it live. You could (of course) create a valid segment name but I decided that by design I would force the use to change the name.

The other fields are set to their equivalent field. So segment type becomes segment type and so on. (Simples!)

Notice that the activation status is draft. This is actually important as I want the copied segment to be in a draft state.

Step Four – Activate

Finally I simply activate the workflow and it is ready to test.

Test

I then wanted to test my workflow. Unfortunately we can’t (yet) run on-demand workflows directly from the UCI interface. (Hopefully we’ll get that capability soon.) To cope with this, navigate to segments and then click the advanced find button. (Se can run an on-demand workflow from advanced find!

You can see in advanced find that I have actually selected all my workflows. You might not want to do that! I have done this simply to test that all types and statuses of segments work. As I have created a mixture of dynamics, compound and static segments.

Once you have selected one (or more) segments use the “Run Workflow” option to trigger the workflow we have just created.

Below you can see that after I selected my workflow I click add.

Back in UCI I need to wait for a few seconds. The workflow will take time to run. After about one minute I clicked the “Refresh” button and my copies have been created. Notice that they are all in draft state.

Being in a draft state I can now I open them, edit as required, change the name and then make live. Below you can see my copied compound segment with the query definition correctly displayed.

This is a simple tip but one I hope will help people working with complex segment in Dynamics 365 for Marketing. Enjoy.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s