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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / changing datasources f...
Power Apps
Answered

changing datasources for dev, test and production stage

(0) ShareShare
ReportReport
Posted on by 21

Hi guys, 

 

I´m building a powerapp where I use different fields from a CRM entity.

This means I have a form on which I´ve placed some fields (datacards) from a datasource that connects to my dev CRM envrionment where I was able to test my progress and see f.e. if the related record is created in CRM. 

 

So far so good. When it comes to testing my progress on different stages of CRM and in the end "Go Live" with the production CRM I need to connect to another CRM (Test or Production) with this app ... 

 

My question now is how I can (hopefully easily) switch the datasource f.e. to my test CRM in my app for all items, that use the development CRM datasource (the datamodels in all CRM stages are identical). 

 

Thank´s in advance for your help.

 

Regards

Joe

Categories:
I have the same question (0)
  • Verified answer
    Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hey Joe,

     

    So if I'm hearing you right, you have one PowerApp that you have been testing with to validate that you can create / read data from a dev CRM entity and are now trying to see how you can switch this from the dev data connector to the test / production connector?

     

    If that is the case, unfortunately there isn't necessarily a one button change for this but it shouldn't be too difficult. Essentially wherever you are referencing the data connector (In a gallery, this would be the items property, or for the form, would be set as the DataSource property. If you look at these properties now, you should see the name of your development connector in single quotes.

     

    If you are thinking of consistently validating concepts first against your dev data and then having your production app separate, you might have a few options to avoid this situation:

     

    1. Create one app for production (shared with the organization) and have another that is private to you and any other testers that is dedicated to just testing / brainstorming.
    2. Have one app that has your dev / test / production data connectors and then create separate pages that can't be navigated too from the live version, but in the web studio can be accessed only by the PowerApp builder. This way you reduce the pain trying to copy components / logic from one app to another and can still test against your other data sources
    3. Try and use a combination of constants / context variables to try and create dynamic logic that can switch all the different places you set the data source between dev / test / prod based on an admin panel that is only accessibly by you.

    Let me know if you have any questions

     

    -Storm

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    this is a real pain point in powerapps. if yo set up a separate environment and copy your app to that new environment, yo should be able to change the data sources.

  • thaJoe_ Profile Picture
    21 on at

    Hi Storm, 

     

    sorry for the late answer, haven't had the chance to test you solutin before ... but good news: 

     

    I wasn't thinking that it´s that easy, but your answer was exactly the switch I needed to switch between the datasources ... so i changed it on the form and that was it. 

     

    many thanks for your help. 

     

    Cheers

    Joe

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    I agree with you. This is an oversight on the development team on pushing this out. In any proper SDLC, you should be able to do something as simple as this.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 342 Most Valuable Professional

#2
11manish Profile Picture

11manish 234

#3
Valantis Profile Picture

Valantis 187

Last 30 days Overall leaderboard