ModsJava
[1.8-1.17] Harmony MySQL | In-Game MySQL GUI | Database Manager
Java mod listed for Minecraft 1.8–1.16. Downloads from the MC Java Mods app on Android.
⬇ Download on Spigot
Description
Harmony SQL is a Graphical User Interface for MySQL inside of Minecraft. It allows server admins to Create / Remove Databases, Create / Remove tables, Add/Remove/Alter Columns and Select Rows all while in game.
Configuration
config.yml is responsible for entering the MySQL server credentials as well as the security method for gaining access.
Spoiler: config.yml
Code (YAML):
mysql:
username : "user"
password : "pass"
host : "127.0.0.1"
port : 3306
security:
password : false
console : false
passphrase : "1234"
username : "user"
password : "pass"
host : "127.0.0.1"
port : 3306
security:
password : false
console : false
passphrase : "1234"
language.yml is reponsible for all the messages in the plugin alongside the prefix.
Spoiler: language.yml
Code (YAML):
prefix
:
"&f[&bHarmony&f]"
messages:
admin:
console_execute : "&fSorry, but this command can only be run by a &bPlayer&f."
console_code : "&b%player%&f's code is &l&b%code%"
config_reloaded : "&fConfig reloaded successfully."
custom_query : "&fType in your &bcommand&f in chat."
create_database : "&fEnter the name of the &bdatabase&f in chat."
create_table : "&fEnter the name of the &btable&f in chat."
create_column : "&fEnter the name of the &bcolumn&f in chat."
first_column : "&fIn order to create the table, you'll need to create a &bcolumn&f."
column_size : "&fEnter the &bsize&f of your column."
enter_condition : "&fQuery: \n\n&b%query%&f\n\n Enter your new condition in chat(or type &bnone&f to cancel)."
player:
no_access : "&fSorry, but this command requires the &bharmonysql.admin&f permission."
no_password : "&fYou must type in the &bpassphrase&f to proceed. (/harmonysql password)"
invalid_password : "&fSorry, but the passphrase you entered is &binvalid&f."
code_sent : "&fYou need to enter the confirmation code sent to the &bConsole&f."
messages:
admin:
console_execute : "&fSorry, but this command can only be run by a &bPlayer&f."
console_code : "&b%player%&f's code is &l&b%code%"
config_reloaded : "&fConfig reloaded successfully."
custom_query : "&fType in your &bcommand&f in chat."
create_database : "&fEnter the name of the &bdatabase&f in chat."
create_table : "&fEnter the name of the &btable&f in chat."
create_column : "&fEnter the name of the &bcolumn&f in chat."
first_column : "&fIn order to create the table, you'll need to create a &bcolumn&f."
column_size : "&fEnter the &bsize&f of your column."
enter_condition : "&fQuery: \n\n&b%query%&f\n\n Enter your new condition in chat(or type &bnone&f to cancel)."
player:
no_access : "&fSorry, but this command requires the &bharmonysql.admin&f permission."
no_password : "&fYou must type in the &bpassphrase&f to proceed. (/harmonysql password)"
invalid_password : "&fSorry, but the passphrase you entered is &binvalid&f."
code_sent : "&fYou need to enter the confirmation code sent to the &bConsole&f."
Commands & Permissions
HarmonySQL has one command with two aliases:
Spoiler: Commands
Code (Text):
/harmonysql
/hsql
/harsql
/hsql
/harsql
HarmonySQL has two permissions:
Spoiler: Permissions
Code (Text):
harmonysql.admin - allows access to the GUI
harmonysql.reload - allows reloading the config with /hsql reload
harmonysql.reload - allows reloading the config with /hsql reload
API
HarmonySQL has a developer API for executing queries inside of databases.
Spoiler: API Usage Example
In order to use the API you need to enable API access in the HarmonySQL config.
If you want to create an instance of the API when your plugin loads, make sure to set HarmonySQL as a dependency.
The API will connect you to the same MySQL server as the credentials in the HamonySQL config.
Example:
Code (YAML):
api_access
: true
Code (YAML):
depend
:
[HarmonySQL
]
Example:
Code (Java):
public
void onEnable
(
)
{
HarmonyAPI api = new HarmonyAPI (Bukkit. getServer ( ). getPluginManager ( ). getPlugin ( "HarmonySQL" ) ) ;
try {
api. setDatabase ( "DATABASE" ) ;
}
catch (HarmonySQLException e ) {
e. printStackTrace ( ) ; //gets thrown if api access is disabled
}
JSONArray rows = api. executeQuery ( "SHOW TABLES" ) ;
for ( int i = 0 ;i <rows. size ( ) ;i ++ ) {
JSONObject row = (JSONObject ) rows. get (i ) ;
row. get ( "COLUMN" ) ;
}
api. executeSetQuery ( "CREATE TABLE..." ) ; //executes query that doesn't return anything
}
HarmonyAPI api = new HarmonyAPI (Bukkit. getServer ( ). getPluginManager ( ). getPlugin ( "HarmonySQL" ) ) ;
try {
api. setDatabase ( "DATABASE" ) ;
}
catch (HarmonySQLException e ) {
e. printStackTrace ( ) ; //gets thrown if api access is disabled
}
JSONArray rows = api. executeQuery ( "SHOW TABLES" ) ;
for ( int i = 0 ;i <rows. size ( ) ;i ++ ) {
JSONObject row = (JSONObject ) rows. get (i ) ;
row. get ( "COLUMN" ) ;
}
api. executeSetQuery ( "CREATE TABLE..." ) ; //executes query that doesn't return anything
}
Quick facts
- Edition: Minecraft Java
- File type: .jar
- Minecraft versions listed: 1.8, 1.9, 1.10
- How to install: Install the matching mod loader (Forge, Fabric or NeoForge) for your Minecraft version. → Download the .jar. → Put it in the .minecraft/mods folder and launch that loader profile.
- Where to get it: Opens on Spigot — not every file is mirrored on our own servers.
Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.
[1.8-1.17] Harmony MySQL | In-Game MySQL GUI | Database Manager is a free Minecraft Java mod. Compatible with Minecraft 1.8, 1.9, 1.10, 1.11 and newer. Downloaded 139 times (via Spigot). Download it and open it directly in the game.