Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

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

Dataverse create new uniqueidentifier GUID column for external system integration

(2) ShareShare
ReportReport
Posted on by 2,706
Hi All
Is there a way to create a second guid column in a table? This is to create link to a external system and here we store guid of external system record from ERP. I know alternate keys but prefer guid since its cuts down extra steps when retrieving records via Power Automate using get row by id from Business Central
  • Verified answer
    Ali Hamza Profile Picture
    153 on at
    Dataverse create new uniqueidentifier GUID column for external system integration
    Hi @
     
    It’s not possible to add another GUID column that can serve as the primary column or be used in Power Automate’s "Get a Row by ID" action.

    Alternate keys will definitely work in this scenario, especially when records already exist or are created before syncing with ERP in Dataverse.

    However, if the record is created in response to an action in ERP (e.g., when the record is first created in ERP and then synced back to CRM), you can pass the GUID from ERP to CRM and set it in the primary GUID field. CRM won’t auto-generate a GUID for the record and will use the GUID provided from ERP.
    For example, if you’re creating a lead from JS code, we’ll write below code. 
     
    Note: Guid must be unique otherwise CRM will raise unique guid error.
     
    var record = {};
    record.subject = "TEST LEAD..."; // Text
    record.leadid = "37cde8bb-a249-ef11-bfe3-00224880ce44"; // Guid
    record.lastname = "TEST Last name"; // Text
    Xrm.WebApi.createRecord("lead", record).then(
        function success(result) {
            var newId = result.id;
            console.log(newId);
        },
        function(error) {
            console.log(error.message);
        }
    );
     

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

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 293,278 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 232,021 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156 Moderator

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans