I am trying to do stats. I have kills and coins stored, but deaths isn't working. I have this: Code: public int getDeaths(OfflinePlayer p) throws SQLException, ClassNotFoundException { String pName = p.getUniqueId().toString(); if (!this.db.checkConnection()) { this.db.openConnection(); } Statement statement = this.db.getConnection().createStatement(); ResultSet rs = statement.executeQuery("SELECT * FROM `data_kitpvp` WHERE `uuid`='" + pName + "';"); return rs.getInt("deaths"); } But it gives this error: Code: [19:40:18] [Server thread/WARN]: java.sql.SQLException: Before start of result set [19:40:18] [Server thread/WARN]: at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1073) [19:40:18] [Server thread/WARN]: at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:987) [19:40:18] [Server thread/WARN]: at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:982) [19:40:18] [Server thread/WARN]: at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:927) [19:40:18] [Server thread/WARN]: at com.mysql.jdbc.ResultSetImpl.checkRowPos(ResultSetImpl.java:841) [19:40:18] [Server thread/WARN]: at com.mysql.jdbc.ResultSetImpl.getInt(ResultSetImpl.java:2672) [19:40:18] [Server thread/WARN]: at com.mysql.jdbc.ResultSetImpl.getInt(ResultSetImpl.java:2813) [19:40:18] [Server thread/WARN]: at dev.imperium.net.database.MySQLManager.getDeaths(MySQLManager.java:166) [19:40:18] [Server thread/WARN]: at dev.imperium.net.events.General_Events.onPlayerJoin(General_Events.java:158) [19:40:18] [Server thread/WARN]: at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [19:40:18] [Server thread/WARN]: at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) [19:40:18] [Server thread/WARN]: at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) [19:40:18] [Server thread/WARN]: at java.lang.reflect.Method.invoke(Unknown Source) [19:40:18] [Server thread/WARN]: at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:301) [19:40:18] [Server thread/WARN]: at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) [19:40:18] [Server thread/WARN]: at org.bukkit.plugin.SimplePluginManager.fireEvent(SimplePluginManager.java:502) [19:40:18] [Server thread/WARN]: at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:487) [19:40:18] [Server thread/WARN]: at net.minecraft.server.v1_8_R2.PlayerList.onPlayerJoin(PlayerList.java:296) [19:40:18] [Server thread/WARN]: at net.minecraft.server.v1_8_R2.PlayerList.a(PlayerList.java:156) [19:40:18] [Server thread/WARN]: at net.minecraft.server.v1_8_R2.LoginListener.b(LoginListener.java:144) [19:40:18] [Server thread/WARN]: at net.minecraft.server.v1_8_R2.LoginListener.c(LoginListener.java:54) [19:40:18] [Server thread/WARN]: at net.minecraft.server.v1_8_R2.NetworkManager.a(NetworkManager.java:231) [19:40:18] [Server thread/WARN]: at net.minecraft.server.v1_8_R2.ServerConnection.c(ServerConnection.java:148) [19:40:18] [Server thread/WARN]: at net.minecraft.server.v1_8_R2.MinecraftServer.A(MinecraftServer.java:809) [19:40:18] [Server thread/WARN]: at net.minecraft.server.v1_8_R2.DedicatedServer.A(DedicatedServer.java:368) [19:40:18] [Server thread/WARN]: at net.minecraft.server.v1_8_R2.MinecraftServer.z(MinecraftServer.java:651) [19:40:18] [Server thread/WARN]: at net.minecraft.server.v1_8_R2.MinecraftServer.run(MinecraftServer.java:554) [19:40:18] [Server thread/WARN]: at java.lang.Thread.run(Unknown Source) The line is this: Code: return rs.getInt("deaths"); I don't even know what Before start of result set means either, but i'm guessing that it can't find the info Ah don't worry. I fixed it. There was something wrong with my database. [SOLVED] EDIT by Timtower: merged posts