web
You’re offline. This is a read only version of the page.
close
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

SQL Triggers / Write access to database ?

(0) ShareShare
ReportReport
Posted on by 5

Hi, I have an online dynamics crm application (xxxx.crm4.dynamics.com) and I'd like to monitor changes (insert, update and delete) on some entities and record those changes into a custom table.

With an SQL trigger it would be very easy to do so but I'm afraid the feature is not supported.

I can connect to the DB using sqlcmd or SSMS but the database is read-only.
Is there a way to gain write access to the database ?
Is it possible to create SQL triggers on the database ?
If not, are a plugin or an action from workflow the only ways to create SQL like triggers ? 

Best regards,
Nicolas.

I have the same question (0)
  • Verified answer
    Wahaj Rashid Profile Picture
    11,321 on at

    Hi,

    Thank you for your query.

    Write access on Database is not supported for online version. Even for on-premise it is not recommended.

    To track changes, you can enable Auditing, which will record any changes made to the records (CRUD) for the configured entities and fields.

    Audit data and user activity for security and compliance - Power Platform | Microsoft Docs

    Please note, there following levels of Auditing:

    • Global Auditing Settings: Go to Advanced Settings -> Auditing -> Global Audit Settings.
    • Entity Level: you can turn on or off Auditing for an entity.
    • Field Level: when auditing is enabled for an entity, you can choose fields to be audited.

    Here is an article on how to enable auditing:

    Enabling Auditing of Dynamics 365 Entities (coveo.com)

    Once, Auditing is enabled, you can see the Auditing Log in:

    • Audit Summary View: Go to Advanced Settings -> Auditing -> Audit Summary View.
    • Entity: open a record to see its Audit Log (Related -> Audit History).

    You can extract Audit Data using:

    Audit History Extractor  Â· XrmToolBox

  • Nikos06 Profile Picture
    5 on at

    Thank you very much Wahaj !

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Tom_Gioielli Profile Picture

Tom_Gioielli 70 Super User 2025 Season 2

#2
Gerardo Rentería García Profile Picture

Gerardo Rentería Ga... 33 Most Valuable Professional

#3
Daniyal Khaleel Profile Picture

Daniyal Khaleel 32 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans