Is it possible to add a report to a data syncronization?

Is it possible to add a report to a data syncronization?

I am currently working on a project in which I am using the script of the following article to synchronize two databases:
I was looking for more articles and I found this second article in which not only a log is created but also a detailed html report:
I was wondering if anybody knew how to implement those reports in the first script.