Jump to content

PHPGraphLib Problems


SalientAnimal

Recommended Posts

Does anyone here use PHPGraphLib?

 

I'm using this on my page to display graphs, but when running a query to get the data, I only get one bar on my graph, despite the fact that I am grouping the information by username.

 

Any help?

 

My Query Collecting Data:

$sql="SELECT *, 
COUNT(*) AS 'queries' FROM product 
WHERE status = 'Open'
GROUP BY username
";  

$result = mysql_query($sql) or die('Query failed: ' . mysql_error());   

if ($result) {  

  while ($row = mysql_fetch_assoc($result)) {   

      $status=$row["Open Query"];  

      $count=$row["queries"];  

      //add to data array  

      $dataArray[$status]=$count;  

  }  

}

 

 

I've run the query in PHPMyAdmin and I get two sets of data.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.