Conditional Sync Of moodle databases

Conditional Sync Of moodle databases

by rajith kumar -
Number of replies: 1

Hi,

     I  would like to sync one master Moodle database against some slave Moodle databases on a specific frequency.For Example would like to sync only the tables related with creation /Deletion of course category and  courses.how can i get the related tables for the specified transaction?i tried to do MySQL profiling .but  it gives a lot of tables.once i get the tables i can customize my replication script to include only these tables.

thanking you in advance

Rajith



Average of ratings: -
In reply to rajith kumar

Re: Conditional Sync Of moodle databases

by Darko Miletić -

Essentially you will have to read the code.

Optionally you can create minimal code examples that perform operations you would like to profile. For example to create course category you could create page like this:


require_once('/path/to/config.php');
$DB->set_debug(true);
$category = \coursecat::create(['name' => 'foo']);
$DB->set_debug(false);

This would create a category and print out ALL queries executed by moodle for that operation.


Average of ratings: Useful (1)