L
L
lzy2019-01-08 20:03:57
Yii
lzy, 2019-01-08 20:03:57

How to work with 2 bases?

For example, I have 1 site, it is required that when adding a new record, this record is automatically added to another database, the problem is that hosting can be different or what is an alternative solution? I need to get sales statistics for each site.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Daniil Kozlov, 2019-01-08
@lzy

The easiest way is to write a rest-api, and with any change on one site, pull the api on the second. Yes, and to obtain sales statistics, this is the most reasonable option.
By means of yii it is easily implemented.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question