How to generate charts from the database

To create a chart, simply go to your  Dashboard > Visualizer > Add New Chart, and select the type of chart you want to create. 

By default, the chart comes with some sample content that you can change, by either adding manual data or by importing it from a different source

In this doc, we'll follow the Import from database method, which allows you to use our query editor to get data from any table and database you want (your own or an external database).

Note: This is part of the premium version of Visualizer. The Personal plan includes just a One-time import, while the Developer and Agency plans include One-time/Live/Each hour/12 hours/day/3 days imports.

1. Get data from your own database

STEP 1

Select the Import from database panel. There you can select how often the import should take place ( One-time/Live/Each hour/12 hours/3 days ). After that, click on Create Query to open our query editor.

STEP 2

In the query editor, you need to enter the query of your choice. Here you can find some sample queries. It's also possible to use PHP variables in the DB queries, an example here.

STEP 3

After entering the query, click on Show Results.

STEP 4

Here you will see the results of your query. At this point, if everything is ok with the query you can click on Save Schedule and Show Chart to see the chart. After that, click on Save Chart.

2. Get data from an external database

If you have an external database from which you want to pull the data, you need to make an extra step. Just before entering the query, make sure you click on the SELECT ANOTHER/EXTERNAL DATABASE which we'll open some new fields.

Select MySQL and enter the Server Name/IP, Database Name, Username and Password of the external database and click on Test Connection. If everything went well, you will see a successful connection message and you will be able to enter your query and generate your chart.

The plugin is compatible with the following types of external databases: WordPress DB, MySQL, SQLite3, IBM DB2, MS SQL, Oracle, PostgreSQL.

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us