0

I am trying to create a column chart that plots the amount of Change Requests (custom content type) created per month, and how many of those Change Requests are successful. The success is indicated by a list field which is set to the option "Fully Successful". So in short, for each month on the chart, there would be two columns. One showing the number of change requests created, and the second showing how many of those change requests are successful.

Here's an example of what I want:

enter image description here

Modules

I am using the Drupal Charts and Views modules to achieve this. I believe I can achieve this with the Charts module because one of the examples in the module page main image shows a very similar monthly chart, but this isn't covered in the docs.

Points of Confusion

  1. How do I count each change requested created per month? (Read attempts section for clarification)

  2. How do I repeat this process for the success column whereby I count how many change requests exist with a list field equal to "Fully Successful" per month?

Attempts

I have spent lots of time reading the Charts documentation, watching the video, and reading blog posts but I haven't had any success yet in my attempts to plot these charts. The docs are great and have some unique examples, but these examples didn't help me better understand how to achieve what I am specifically trying to achieve. Additionally, I did a quick search for existing issues on the Drupal forum but wasn't able to find anything.

  1. As a clarification for point 1, I attempted to create this by adding a new field for "Authored on" and setting the aggregation to count but this creates a new data point for each unique date & time the change requests are submitted on, and gives each a count of 1. Instead, I just want the chart to display 12 data points, one for each month, and to count how many requests exist for each month.

I don't have more attempts to list here because my inability to chart the data per month prevented me from attempting to repeat the process for the second column.

Conclusion

In conclusion, I was hoping someone could advise me on how I can achieve what I am going for. Any kind of help would be very useful as I have been stuck on this for weeks with very little progress.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.