<?php
error_reporting(0);
     include_once('../config/conn/db-connection.php');

         $q = $db->query("SELECT count(*) as num, educational_attainment FROM tbl_beneficiaries GROUP BY educational_attainment")->fetchAll();
         $chart_data="";
         foreach ($q as $row) {
 
            $educ_At[]  = htmlentities($row['educational_attainment']);
            $count[] = htmlentities($row['num']);
        }
 
?>