- Баллы
- 76
- Имя в Minecraft
- _MasterCapeXD_
Я только начал изучать работу с MySQL, по-этому не знаю как убрать
ошибку. Саму таблицу я достаю так:
Код:
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table 'table' doesn't exist
JavaScript:
private String host, database, username, password;
private int port;
public void onEnable()
{
File config = new File(this.getDataFolder() + File.separator + "config.yml");
if(!config.exists())
{
this.getConfig().options().copyDefaults(true);
this.saveDefaultConfig();
}
host = this.getConfig().getString("mySQL.host");
database = this.getConfig().getString("mySQL.database");
username = this.getConfig().getString("mySQL.username");
password = this.getConfig().getString("mySQL.password");
port = this.getConfig().getInt("mySQL.port");
try
{
openConnection();
} catch(ClassNotFoundException e)
{
e.printStackTrace();
} catch(SQLException e)
{
e.printStackTrace();
}
}