I need to create a monthly sales report in Drupal. The report should contain products/services sold during last month, quantity and the price. Sales persons have to enter monthly the information in the report. I am thinking to create the products as a content type Product with the field Month, Name, Quantity, Price, Sales person (Author).

If I display in Views the Content Type - Product, how can Users (Sales role) enter the Quantities? How to control that the quantities for all products are set? How to limit it to 1 Report per month? How to identify which users have entered the report and which users didn't do it?

I would appreciate very much if you can guide me how to better achieve this monthly reporting objective!

1 Answer 1


This seems like a perfect usecase for the Forena module. Forena is built of the idea of using SQL to get data out of a database and use XHTML and CSS to format it into web reports (and/or charts). Various DBMSs are supported, such as Oracle, MS Sql, Postgress, SQLite, MySQL, any PDO compliant DBMS ... And there are quite some reasons for considering Forena.

Visit the Forena HowTos page for some links (near the bottom) to some live demo / showcase links, and experiment a bit with some of its demo samples.

Some of its features that I think will help to answer this question (and which only is a matter of minutes to deliver the features you're looking for):

  • Create a report about "products/services sold during last month, quantity and the price." Have a look at the "Northwind database" demo videos, which I tink are pretty close to what you're looking for. Such as these videos:

  • If you don't want to implement some validation about "... that the quantities for all products are set?" ... (or cannot do so for whatever reason), then you could create a report to find all cases that violate (as an alternative).

  • To create a report about "identify which users have entered the report and which users didn't do it?"

Disclosure: I'm a co-maintainer of Forena.

  • Thank you very much for your prompt reply. Forena looks like a very good product and I am definitely considering it for creating reports. However, at this stage, my question is more how to better include the data into the database? To create one big form with the Form API? Each line of the form is product name + quanty + price/unit and total price. Or to create a Content Type "Product" with all these fields. Create 20 nodes of type Product, display them with Views with the option to edit field Qty and after save create New 20 nodes of type Product. Or to have Product names as a taxonomy term..
    – Simbase
    Dec 13, 2015 at 18:46
  • thank you for this extra info. It'll help me to enhance my answer, which I plan to do tomorrow. For now: seems to me like you "only" need some relevant content types (+ fields) to enter the various data, and some tools related to it to facilitate the editing (data entry) for your users. Add to that some business logic (and the forena features as in my answer and you should be close). Dec 13, 2015 at 18:55

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.