There have been several posts on the environment variables, but I think Microsoft just released a pretty GREAT update recently. I honestly don’t have a clue when this function was released, but it made my day a LOT easier:) This is how we used to refer to Environmental Variables:
Sure you can migrate variables/records between systems and be sure to never overwrite, but it can be time consuming to maintain.
Microsoft has introduced environmental variables to Dynamics / Dataverse to fix this exact problem. You create a new Environmental variable in your solution, and you can se the value for each environment. Within CRM you can refer to the environmental variable instead of hardcoded values:)
Within the solution explorer you can add Environmental variables that can be used across the different systems. In this test I am using a variable to define what environment I am working in “Test or Production”.
I wont be writing about the Environment variables in detail, as you can read more about them in other posts, but I wanted to cover the new way of using this within Power Automate!
Accessing the Environmental Variables in Power Automate Flow
Start by creating a new Power Automate, and add compose function
Check out that bad boy! 🤗😎 No longer need for get record calls from entities etc. A nice improvement that will save a few minutes here and there.
There are many ways of getting the current environment URL, but this is the quick and dirty version of doing just this 😏 Next week I will post about Environment variables as I know this is a possible approach that is better.
The intention about this blog is to show how to use Json to parse just a small part of an action body to get what you want exposed.
So this could be a typical flow in Power Automate for Dataverse. We have a trigger on top and an action below to get more data from the element that triggered.
The BODY of the trigger doesn’t contain environment information, but only Opportunity data:
But the Action contains a lot more interesting data for this.
In order to get this data we need to parse the Json returned here to retrieve the “Odata.ID” that includes the URL for our environment.
I will keep calling it CDS Lite in the smallest hope that this one day might get the name CDS Lite. It just makes perfect sense to give it a name like this. Allright, enough about the hope for a better naming future…
I know the system is only in preview and many things will change in the next months, but I thought I would give it a go at importing data from CDS to CDS Lite. I had no idea if this was possible, but I was curious to see how it would react.
At the moment there is no connecting to the database through normal tools I have had before
SSIS – KingsWaySoft
Every time I try to connect I get the response saying that I have to use an Oauth method to connect.
PS: Notice how Microsoft has put “LITE” in the error message? It’s a small hope, but it’s a hope 😂
So the only way I found out how to insert data in the Preview was via flow
Flow to the rescue
I am pretty sure that the current doc recommends using Flow for data to CDS Lite (Oakdale), but I am sure this will change in the future somehow. How else are you going to fill 2 million records (estimates from docs on the 2 gig DB size). Flow is not intended for data migration, but I had to use the tools I had available at the time 🙂
First I imported 5694 accounts to my CDS database (top row headings)
The CDS Lite (Oakdale) was empty for accounts, and only included the following columns.
The flow was a little tricky. I actually had to create the flow from the CDS Lite (Oakdale) environment. It did not work otherwise. Current environment connector was fine for writing to CDS – Lite (Oakdale).
The flow will only do 512 records if you don’t open up the paging. Go to settings of the connector and increase the threshold.
I started the flow and patiently waited.
27 minutes later the accounts had been migrated with a warning. I could only find 1 error in the migration, so I consider that a success. All of my accounts were now over to the CDS Lite (Oakdale).
This is all just a beginning of a longer journey for the CDS Lite (Oakdale). Everything is in preview, so there are many things that will change once this is released, and a few years from now. I just wanted to see how to get data in to the system. The reason why might be more clear in a later post where I describe what I see in a future customer scenario for CDS and CDS Lite.
Sarah and Marius were speaking of Equal Opportunity. A highly interesting topic that is as relevant today as ever before. One slide caught my eye that I really liked.
Take ownership of your own environment. Don’t wait for others to create an equal opportunity environment, and then complain if they don’t. If you see the chance to own a situation, take it.
If there is a table you want to sit at with a chair, take the chair and sit down. Don’t wait for others to offer you a place at the table. You take it if you want to be a part of it!
Sarah Critchley (quote as I could remember it)
I have grown up in a family where the women are strong, have great educations and excel at their jobs. I am sure they have faced issues along the way, but they keep claiming their place at the table every time they can.
Malin Martnes – Extending Talent
I am sure you all know how proud I am of Malin, so I couldn’t go without writing about her. Talent is not a product with lots of customers yet, but we are working on a lot of exciting opportunities at the moment. We are always in the challenger position when talking about this product going head to head with companies that have delivered HR for many years. This often ends up in a function feature comparison, but one thing we now can focus on is the ECO-System.
Talent integrates to the CDS, and therefore we can leverage all of the cool features of the PowerPlatform. Malin showed a lot of cool examples where PowerApps were assisting in the hiring process.
What I liked about this session was hot interactive it was, and how “low code” he was trying to make it. I gained some insights to the IOT challenges when gathering messages in different ways. Also I see the impact of having a device you can pass around in the room that is working while presenting. It was showing live data on the screen, presenting different messages to us as we were passing it along. He later posted the slides on Twitter
Jukka Niiranen – Canvas vs Model
I find it interesting to listen to Jukka. He is like a rapper’s lyrics when talking. There is often some deeper meaning to what he says if you listen closely. During this session he was open and honest about his view on the Canvas apps, and the battle Canvas vs Model is now facing. Will we ever get to the point where these 2 become 1? The answer is most probably, but how!! 🙂
He also had a wonderful slide with the great Scott Durrow in focus. I think we all agree that Canvas is absolutely becoming a code app, even though it might not be complex code. As a functional consultant I say code, but a developer says “cody” to the syntax;) hehe
The pictures bellow are from Mark’s session. I really loved this session because he made the participants work! The topic was CDS modeling and what you should think about. He made it clear what was out of the box, and how you should begin to think about creating new models not based on the standard applications.
Anything interactive like this is just AWSOME. The participants loved it, and had a great time while working together on the data model. Interactive learning is the best way to learn.
So in conclusion, I had a great time at this event. Hope to repeat this again next year in Oslo. I also hope to see you all again soon:)
So Power Platform Oslo was a unique experience for me, since it was the first time I was on stage at a community event. Marius Agur challenged me to create a presentation that would showcase my view of Dynamics from a business perspective. I am not the most technical person, so I try to create solutions based on simplicity for the end user within a “do it yourself approach”.
3 ways the Power Platform can increase user adoption
I was using our own company as example for this demo, and demonstrating the issues we have had when migrating from HubSpot to Dynamics 365. A journey with lots of bumps in the road, and long nights to figure out the best solution.
1. Connecting Flow to API
Part One showed how we can connect flow to an API and receive real time data from sources like Bisnode, Proff.no or in my case BRREG. I will blog about how to do this soon.
2. Creating a PowerApp for simplicity
Part 2 was showing how you can create a powerapp to simplify not only the user input, but also create a bridge between those who don’t like Dynamics CRM, but accept using a PowerApp, because it is new and fun. Blog about this will also come soon.
3. Integrating to onpremise data source
The last step was showing how we could integrate our CDS/CRM solutions to an onpremise ERP solution without a single line of code. Read more about hit HERE
People to thank
Chris Huntingford: @TattooedCRMGuy I would never have even thought of doing community or personal exposure if it were not for your exceptional outgoing personality motivating me when you where in Oslo. I know it sounds odd, but I wanted to be like you, and spread excitement and joy to others. Somehow you made something in my brain say “why not” create a blog and speak my mind! MASSIVE thanks..
Megan Walker: @MeganVWalker Getting to know you and understanding how you use the tools in regards of blog, wordpress, youtube has been very important. You were also so kind to be my first interview subject 🙂
Mark Smith: @nz365guy Thank you for hosting the 90 day Mentoring Challenge. Even though you were speaking to the masses, you make it personal to participants. I have also shared many conversations with you that mean a lot to me. Thank you for guidance in som many different levels in regards to creating a profile. I might not be the fastest at getting everything done, but I will get there.
Malin Donoso Martnes: @MalinMartnes Thank you for being persistent in your work. It inspires others to try:) You gave me the final push to submit my talk, and I don’t regret it!
This week I needed to use the List Records function, and I realized that I had no idea how to use the filters. Thank you Jonas Rapp for creating the FetchXML Builder!! The function “Flow List parameters” saved my day:)
Let’s begin with the simple filters where I get a contact with the last name of Sandsør
Test your search result with the Execute button so see that anything is actually returned. Then open the Flow List Parameters
The tool converts the Fetch XML, and magically gives the correct filter to add in our FLOW query. It can’t get much simpler than that!!
Lookups act a little bit different with the syntax, as lookups always to. This got me quite confused before finding this tool, because I was not getting match to my result.
I am searching for contacts with a given GUID. In my case I didn’t know what the GUID was, so I randomly generated a GUID for the formula. In FLOW I substituted the GUID part of query with a dynamic variable.
Filter Query with lookups, you need to add “_” as seen above. When working with lookup you won’t get at match without the “_LookupField_Value”.
Filter linked entity
The last filter is a little more complex, and might not get used due to some limitations of Odata (Must match on unique ID for related).
In this scenario I wanted to locate all contacts with last name “Sandsør” where the regarding accountID = GUID.
Choose the main entity on top, and add “link-entity”
Make sure you have the correct relationship here. Some Lookups support more than one entity, and therefore you make sure you have the correct one.
Again we find the magic with the “Flow List Parameters“.
In this scenario we also get Expand Query result that we need to copy/paste.
Apply to Each
Once you have figured out what filter to use, you can select the “Apply to Each” function, and add custom logic in here.
One confusing obstacle with a new CRM system, is the connection between Dynamics CRM and SharePoint. As a consultant I often have to demonstrate what is really happening behind the scenes to justify why this isn’t straight forward. We have to tell the customer about different folders, different entities etc, while they simply don’t care. They just want it to work together.
One particularly interesting point is when they move between entities. Why can you work with documents in the Lead, and when you navigate over to Opportunity, you no longer see your sales documents? Technically I understand why, but from a functional perspective I understand the customer.
Recently I ran into this scenario when implementing Field Service. Sales produced documents what were important throughout the whole cycle Sales -> WorkOrder -> Assett. Navigating between the entities takes to long, so the challenged me to find a solution.
FLOW TO THE RESCUE ❤
When the opportunity was done, we needed to create 1 or more WO in Field Service. Important factor was to maintain all the work done in Opportunity with the documents, so the Field Service Technicians could see everything in one entity (WO).
Challenge: When I create a new Work Order from Opportunity, I need to copy the document location from the originating Opportunity.
Flow begins with a simple trigger. When a WO is created.
Then I check to see if the related Opportunity contains data. This is just to make sure that the WO actually is created from a Opportunity.
Then I needed to get the document location regarding the Opportunity. As you can see here I am only returning 1. There won’t be any more document locations on Opportunity the way they are using it now. If you wonder how to filter, check my other post LIST CDS RECORDS IN FLOW
This is where I create a new Document location, and set the Work Order as regarding. Flow will automatically add “FOR EACH” to loop through. In my case it doesn’t matter, because I only have 1 document location from Opportunity.
What the user sees
This is a new Opportuinty
The opportunity has documents related to it.
I then convert the opportunity to Work Order via the button in ribbon. I get a message when this is complete.
I open the document location of Work Order, and VIOLA, the same documents.
Personally I love finding quick wins like this that mean a lot for simplicity. Any CRM application will be complex for the end user, so these parts help:)