web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Answered

How to set statecode (Draft/Active/Retired) when using dataflow to import products from external database?

(0) ShareShare
ReportReport
Posted on by 2

Hi community,

I'm using dataflow to import products from an external database into Dynamics (the Product table). After adding an alternate key to both Unit (name), UnitGroup (name) and Product (number) it works all right. However, I am not able to set the statecode/statuscode for the product. Those fields are not existing in  the column mapping section of the dataflow:

pastedimage1656505215624v1.png

I am also unable to find the Option Set for statecode and statuscode - thinking that I might add som alternate keys there as well.

The source database have a column stating wether a product is retired or not, and I want to use that to set statecode in Dataverse as well.

Anyone tried the same?

Thanks in advance,

Ola

I have the same question (0)
  • Verified answer
    Ram Prakash Profile Picture
    2,287 on at
    RE: How to set statecode (Draft/Active/Retired) when using dataflow to import products from external database?

    Hi,

    Dataflow is used to Create a new Record.

    Create a Dummy Field and Store the Status then Create a Process

    1. Click Gear Icon at the top

    2. Select Advance Settings

    3. Click Settings --> Select Process --> Click New and input name and select entity

    4. Select When a Record is Created

    5. Add a Step called IF CONDITON Select the Dummy Field which you have Created and (Dummy field = Draft) then Change the Status

    6. Like way add else condition too

    Please mark as Answer if it is helpful and provide Kudos

    Subscribe : www.youtube.com/.../UCnGNN3hdlKBOr6PXotskNLA

    Follow me on Twitter : @rampprakashd

    Blog : microsoftcrmtechie.blogspot.com

  • Olasan Profile Picture
    2 on at
    RE: How to set statecode (Draft/Active/Retired) when using dataflow to import products from external database?

    Thanks Ramprakash, this was my conlclusion as well. I was hoping that I had missed something, and that it was possible to actually update this field directly from a dataflow. I can see that this was an "idea" submitted as early as 2019, but as you states - it is not yet possible.

    Ended up with a custom field this time, and just ignores the statuscode all together.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Rishabh Kanaskar Profile Picture

Rishabh Kanaskar 228

#2
Tom_Gioielli Profile Picture

Tom_Gioielli 156 Super User 2025 Season 2

#3
MVP-Daniyal Khaleel Profile Picture

MVP-Daniyal Khaleel 149

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans