It's possible to create a trigger in CRM 365 Database that fire console application everytime a new record is created in CRM ?
*This post is locked for comments
It's possible to create a trigger in CRM 365 Database that fire console application everytime a new record is created in CRM ?
*This post is locked for comments
You can't add anything to the database. But you could use Microsoft Flow to automate a process between two systems.
Fikri the SQL database works as any other database, it has a special structure but it works as any other, If you want to find a correct reason to not edit the database and look for other workarounds please see this link :
I didn't find a link to a microsoft site, but editing the database for CRM is no supported, this is the main reason to see other options, the proxy you have on you organization need to have an execption to permit the communication between one server to the other
So i need to write plugin that sent records into another (temporary) SQL Database, not the CRM Database itself ? And create trigger within this temporary database to run my console application ?
By the way, I have tried to register my console in the CRM Database, and create Trigger in this database. Then i test this trigger by creating a records in CRM. But i think that the trigger not working, because when i check to the newly created record, its not updated like i want.
I think that the trigger not detect insert process from CRM application. Is it ? I need the right reason why the trigger not working in this case. So i can tell my boss to use your suggestion.
Fikri I get your point, I can think in two different options
Hi Sergio,
We want to synchronize our CRM 365 On-Premise with CRM Online using this scenario:
In CRM Online, when a new opportunity records is created, the system will send email to an account in CRM 365 On-Prem that contain opty number (unique field) of the new created opportunity. Using Auto Case Creation in CRM 365 On-Prem, we will created a new opportunity record based on opty number we recieve from CRM Online in email. Since the email just contain opty number, the rest of opportunity fields are still empty.
In order to get the rest data of opportunity records (opty name, owner, createdon and etc) in CRM Online, we creating a plugin that will get the data from CRM Online based on the opty number, and updating CRM 365 On-Premise with those data. But, in the middle of work, we knew that plugin won't work for our CRM system, due to proxy setting within our organization.
So we want to use console app that get opty number and guid in database, and do query to retrieve records in CRM Online based on opty number, and update the recordsi in CRM 365 On-Prem based on its guid.
Hi Fikri Microsoft does not recommend alter the CRM database as you can lose its warranty, but what I can suggest to you is:
If you want to execute server code or code that you already have in your console you might want to use a Plugin, plugins can execute server code.
Or in case your console is a must, I will recommend one more time to use a Plugin but this time insert the record in an intermediate database so you don't have to alter the CRM Database.
If you give me more details on what you want to do I can think on more workarounds
André Arnaud de Cal... 291,735 Super User 2024 Season 2
Martin Dráb 230,466 Most Valuable Professional
nmaenpaa 101,156