vendredi 23 juin 2017

Count options percenatge in laravel

I want to show percentage like how many users selected which option for each question,

Q1: How is your overall experience?

A)option1 -25 %

b)option2 -25 %

c)option3-25 %

d)option4-25%

the database looks like this

    user_id  question_id  answer_id
     1            1           1
     2            1           2
     3            1           3
     4            1           4

How can I get above output??please any can suggest.



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

Aucun commentaire:

Enregistrer un commentaire