MySQL Top
MySQL Top v1.0
Description
Please, leave comments if you're interested in further development of this plugin. I've developed it for my own server but felt like other Bukkit users might find it useful.
MySQL Top is a plugin that will fetch data from a specified Table in your MySQL Database and display on signs or as a list in chat. The best way to describe it (imho) is displayed on the image below:
![]()
Features
- Displays information from a specified table in specified order on signs
- Displays information above in chat, whenever /toplist <ListName> is accessed
- Updates information on signs every 30 seconds
- Fully configurable lists
- Doesn't require knowledge of MySQL Syntax
- Basic knowledge of MySQL syntax will make installation and use easier.
Usage Example
For usage example please refer to this page.
URL: http://dev.bukkit.org/bukkit-plugins/mysql-top/pages/mys-ql-top-usage-example/
Configuration
Configuration is pretty self-explanatory. Here's an example of default config.yml:
# MySQL Top Config # If set to true, will enable the plugin, while setting it to false will disable the plugin. enablePlugin: true # Set this to true to tell plugin you've configured the plugin. # This setting is here to prevent plugin from attempt connection # with dummy settings. pluginConfigured: false # If you're not familiar with MySQL and MySQL configuration, you'll probably find this part ambigious. # In this case, it's not recommended for you to use this plugin. # Your MySQL host (Default: localhost) host: "localhost" # MySQL port !!! AS A STRING !!! (Default: 3306) port: "3306" # Your MySQL username. (Default: root) user: "root" # Your MySQL user's password. (if default user is "root", pass is usually "" [null]) pass: "" # MySQL database to fetch data from. There is no default, it should be created by you or someone else. db: "minecraft_db"
Commands
| Command Name | Description |
| /mysqltop help | Displays help section of the plugin. |
| /mysqltop define <List Name> | Creates a list with name <List Name> |
| /mysqltop set <List Name> ispublic <TRUE or FALSE> | Defines if the list can be accessed using /toplist <List Name> |
| /mysqltop set <List Name> table <Table Name> | Defines table from which data will be fetched for the list |
| /mysqltop set <List Name> display <Field Name> | Defines field which will be displayed in the list |
| /mysqltop set <List Name> orderby <Field Name> | Defines field which the list will be ordered by |
| /mysqltop set <List Name> order <ASC or DESC> | Defines the order in which the list will be displayed |
| /mysqltop set <List Name> color <Color (e.g. &4)> | Defines the primary color of the list |
Table, display field, order field and order are required for the list to function properly.
Permissions
| Permission Name | Description |
| mysqltop.admin | Gives access to all commands beginning with /mysqltop |
| mysqltop.toplist | Gives access to /toplist <List Name> |
Info
PM me if you have any problem, or If you a general comment on a project leave a comment here.
Source is coming

-
View User Profile
-
Send Message
Posted Feb 9, 2014Perfect, this will help with CoreProtect.
-
View User Profile
-
Send Message
Posted Jan 16, 2014@limych
Nice suggestion, but what exactly do you mean by "too frequently"?
Do you mean you don't want the lists to update so frequently or your lists don't update as frequently?
If it's the second case, there is no need to worry, process taking place each 30 seconds doesn't really take much resources to run. If it's the second case or you just find the amount of output in the console annoying, you'll have to wait for a future updates.
As you can see, there's a very limited demand on this plugin (what I've pretty much expected, as I've released something I was just making for myself) and I'm not really sure if it's good idea to continue its development.
-
View User Profile
-
Send Message
Posted Jan 8, 2014What a you think about manual setting the interval of refresh top? Every 30s for me is too frequently
-
View User Profile
-
Send Message
Posted Jan 6, 2014@MadGrover
You can do it by editing MySQLTopLists.yml
-
View User Profile
-
Send Message
Posted Dec 30, 2013How can I delete a Mysql List?
-
View User Profile
-
Send Message
Posted Dec 23, 2013@hammernaut
@mobilephone2003
The file was verified, download now!
-
View User Profile
-
Send Message
Posted Dec 23, 2013Sweet idea! I will give it a try. Where can I download from? I don't see an active download link. Do you have a screengrab of the in-chat view?
-
View User Profile
-
Send Message
Posted Dec 23, 2013@Timbo_KZ
I'm a software engineer by trade. I've been playing around with java a bit to do a Forge mod for my kids. I am always pleased when I see mod/plugin authors going mySql for settings and such.
-
View User Profile
-
Send Message
Posted Dec 23, 2013@Dad_Yoshi
Nice idea! That's a likely feature for future updates but I've planned to release a basic version first to see if people are interested.
I'll look into that, thanks for menitioning SQL injections! Actually, and that's a thing worth mentioning, what the plugin does is just putting arguments you specify into a "SELECT" query, and I would definitely make the query more customizable. The problem is that, as far as I'm aware, very little of Bukkit users are familiar with MySQL and its syntax.
You seem familiar with coding, which programming languages are you interested in? I can provide you with a nice MySQL API which will help you accompish your goals.
-
View User Profile
-
Send Message
Posted Dec 23, 2013How about having the ability to load a SQL script from a file? This way I could create a multitable query to return the specific results I want.
You could put in some basic SQL injection prevention by only allowing statements which begin with 'SELECT' and don't allow semi colons in the file.
Thanks
-
View User Profile
-
Send Message
Posted Dec 22, 2013Very much interested in this, have several things I can use it for.
Pumped for release!