lundi 3 septembre 2018

Laravel - multiple database connection get average from 3 tables

I have 3 databases

db_1 (students table)

id | students
1  | 42

db_2 (students table)

id | students
1  | 31

db_3 (students table)

id | students
1  | 22

In my controller, how can i get the total average of all students by using only one model (Student). and by just overriding the database connection.



from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/2Q2W3K3
via IFTTT

Aucun commentaire:

Enregistrer un commentaire