I'm playing around with Google Charts and some sample data in Google Sheets. I can draw a basic chart but having issues with doing a WHERE query. Can't really find any good documentation or samples either, strangely enough.
Anyway, trying to do this:
var queryString = encodeURIComponent("SELECT A WHERE B='Mag A', SUM(C) GROUP BY B");
var query = new google.visualization.Query('dataurl?headers=1&tq=' + queryString);
and can't figure out how to write the query to get it right.
The issue can be seen here: https://codepen.io/paperhack/pen/JgbXwN
the syntax should be in order like:
"SELECT A,SUM(C) WHERE B='Mag A' GROUP BY A"