cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
connor
Level: Powered On

CDS' CRUD Relationship with Traditional DB Systems Using Model-Driven Apps

Hi There,

I am trying to understand a couple of things surrounding how CDS works with other traditional DBs (SQL Server, Orcale, etc.). Also, I am trying to wrap my head around data sources for Model-Driven Apps

A few questions:
1. It seems that Model Driven Apps can only use CDS as the datasource. Is this true? 
2.  Given that my data in is a traditional DB, it would be required to move the data to CDS if wanting to build a Model-Driven App?
4. Is it true if moving to a CDS as the data source, the traditional DB receives the same CRUD actions when the CDS updated? Or does the traditional DB die?
5. If using CDS, does Microsoft assume the user to stop using the traditional DB? What is the expected practice around all of this? 

I greatly appreciate any and all help understanding this subject. I cannot seem to find clear Microsoft documentation on topic. 

- Connor 

1 ACCEPTED SOLUTION

Accepted Solutions
DavidJennaway
Level: Powered On

Re: CDS' CRUD Relationship with Traditional DB Systems Using Model-Driven Apps

Model-driven apps necessarily use CDS as the data store. One key reason for model-driven apps is to have this tight-coupling between the data and metadata, and the app. If you want to use other data stores, I'd suggest using a canvas app It is possible to create 2 way integrations between DB2 and CDS, using the CDS/Dyanamics 365 Web API, but it's a fair amount of development effort, especially if you need a robust conflict resolution mechanism. For data that is read-only in CDS, you can create a virtual entity that maps to the DB2 data, but that doens't sound like it's sufficient for your scenario
2 REPLIES 2
THA
Level: Power Up

Re: CDS' CRUD Relationship with Traditional DB Systems Using Model-Driven Apps

Can someone give an answer to these questions? In particular 4. & 5.?

We are about to build a PowerApp and need to read/write data to a DB2 database and have realized things would be a lot simpler if we could simply mirror the DB2 tables to a CDS and then read/write to the CDS. But the changes to fields in the CDS then have to sync back to the DB2 database for us otherwise it would be pointless. We can unfortunately not abandon the DB2 database either since other systems use it to retrieve data as well. 

 

Is there a way to set up two-way sync for a DB2 database and a CDS?

DavidJennaway
Level: Powered On

Re: CDS' CRUD Relationship with Traditional DB Systems Using Model-Driven Apps

Model-driven apps necessarily use CDS as the data store. One key reason for model-driven apps is to have this tight-coupling between the data and metadata, and the app. If you want to use other data stores, I'd suggest using a canvas app It is possible to create 2 way integrations between DB2 and CDS, using the CDS/Dyanamics 365 Web API, but it's a fair amount of development effort, especially if you need a robust conflict resolution mechanism. For data that is read-only in CDS, you can create a virtual entity that maps to the DB2 data, but that doens't sound like it's sufficient for your scenario