Separate sql queries with ";" if you would like to use multiple queries to build comparison graphs. See example Some supported dynamic tags can be used in your query: {current_user_id},{current_user_login},{current_user_email},{current_user_display_name}.
Step 3: Set Arguments and Values for a Chart - See Example 1
and Example 2
Label for X axis:
This is just label text for a query argument, you can type any desired name here.
Label for Y axis:
This is just a label text for query's main value, you can type any desired name here.
Use ";" separated label names if you have more than one query inside SQL CODE field.
SQL column name of X axis:
Write corresponding SQL field/column name here. f.e. display_name, post_date
SQL column name of Y axis:
Write corresponding SQL field name here. f.e. post_count) - Use one single output name even if you have multiple queries in SQL CODE field.
Note: WordPress supports MySQL only Databases, to use non-MySQL databases some custom PHP code&driver would be needed.
To discuss how to build that you can contact us.
Enter dynamic filter variables using the format described below:
Use this format: variable_name~default_value~variable_label~variable_type | variable_name~default_value~variable_label~variable_type etc.
variable_name - any single name you want.
default_value - default value when no any variable chosen by a user
variable_label - Label which would be visible at a form above the chart
variable_type - number, text or date
~ is a separator between variable elements.
| is a separator between variables
For example if to put limit_tag~10~Count~number | post_date_tag~2010-07-05 17:25:18~Date Published~date here,
then you can use this SQL code select * from wp_posts where post_date<{post_date_tag} limit {limit_tag} in SQL CODE field.
{post_date_tag} and {limit_tag} would be replaced with dynamic variables.
So, the plugin will automatically recognize it and put corresponding selectboxes above the chart.
Text shortcode: [gvn_schart id="ID;
?>"ID,'guaven_sqlcharts_tablepart',true)!=''?' table="1"':''; ?>]
Note: Shortcodes supports width and height attributes. F.e. [gvn_schart id="1" width="500" height="400"]. If no attributes, default width, height (which you enter in this page above) will be used.
Save Changes and See Live Demo
ID . '" '.(get_post_meta($post->ID,'guaven_sqlcharts_tablepart',true)!=''?' table="1"':'').']');
}
?>