chart loads data from mysql