DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:sqlquery

This is an old revision of the document!


SQL Query Plugin

Compatible with DokuWiki

elenor of tsort

plugin Processing query to MySQL databases and display results as a table

Last updated on
2016-11-25
Provides
Syntax

This extension has not been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues.

Similar to sqljson

Tagged with database, mysql, query, sql

Description

Do you want to display data from your MySQL database in DokuWiki? No problem! This simple plugin processing query to MySQL database and displaying results as a table. You also may use it with DataTables Plugin for more usability such as – sorting, searching and etc.

Please donate if you like it.

Syntax

Basic syntax:

<sql>query string</sql>
  • query string – SQL query to perform against the database.

Examples

Perform a simple query to display all records from the table “table”:

<sql>select * from table;</sql>

Using together with DataTables Plugin:

<datatables>
<sql>select * from table;</sql>
</datatables>

Configuration and Settings

The plugin can be configured via the Configuration Manager

Option Description Default value
Host DNS name or IP address of MySQL server localhost
DB MySQL database name (empty)
user MySQL user name (empty)
password MySQL password (empty)

Change Log

  • 2016-11-25
    • Initial release

Discussion, feature requests and bugs

Hello!

I'm using your great plugin SQL Query Plugin in combination with datatables plugin ! It works great and fullfill my needs greatly!

However,when I try to use a query within a table, I have some disturbing layout issues : Impossible for me to avoid my table to display a line above my query result and an header in the table

my query is

Name<sql>SELECT last_name as“” FROM DBuser WHERE user_id = 1 </sql>
Firstname<sql>SELECT first_name as“” FROM DBuser WHERE becountp_id = 1 </sql>
Title<sql>SELECT title_fr FROM DBuser WHERE becountp_id = 1 </sql>

I'm using several plugin in my dokuwiki configuration, especially Bootstrap template 3; I cannot use the option Header-rows=“true” or other options from datatables seems not to work. Have already seen that issue? Any idea how to solve that?

Thank you for your work !! regards

Please e-mail me!

plugin/sqlquery.1510048370.txt.gz · Last modified: 2017-11-07 10:52 by 193.191.223.190

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki