Can't change currency rates
GaburaisuVGC opened this issue ยท 1 comments
I created two currencies, and I wanted to change the rates every month.
However, when I tested to change the rates for the second times, this happenned in the console :
[18:49:06 INFO]: GaburaisuVGC issued server command: /currency exchange Gemme E-Gemme 0.008 [18:49:06 WARN]: org.h2.jdbc.JdbcSQLException: Column "FROM_CURRENCY.NAME" not found; SQL statement: UPDATE cc3_exchange SET amount=? WHERE from_currency.name=? AND to_currency.name=? [42122-187] [18:49:06 WARN]: at org.h2.message.DbException.getJdbcSQLException(DbException.java:345) [18:49:06 WARN]: at org.h2.message.DbException.get(DbException.java:179) [18:49:06 WARN]: at org.h2.message.DbException.get(DbException.java:155) [18:49:06 WARN]: at org.h2.expression.ExpressionColumn.optimize(ExpressionColumn.java:147) [18:49:06 WARN]: at org.h2.expression.Comparison.optimize(Comparison.java:178) [18:49:06 WARN]: at org.h2.expression.ConditionAndOr.optimize(ConditionAndOr.java:130) [18:49:06 WARN]: at org.h2.command.dml.Update.prepare(Update.java:181) [18:49:06 WARN]: at org.h2.command.Parser.prepareCommand(Parser.java:247) [18:49:06 WARN]: at org.h2.engine.Session.prepareLocal(Session.java:461) [18:49:06 WARN]: at org.h2.engine.Session.prepareCommand(Session.java:403) [18:49:06 WARN]: at org.h2.jdbc.JdbcConnection.prepareCommand(JdbcConnection.java:1189) [18:49:06 WARN]: at org.h2.jdbc.JdbcPreparedStatement.<init>(JdbcPreparedStatement.java:72) [18:49:06 WARN]: at org.h2.jdbc.JdbcConnection.prepareStatement(JdbcConnection.java:277) [18:49:06 WARN]: at com.greatmancode.com.zaxxer.libs.hikari.pool.ProxyConnection.prepareStatement(ProxyConnection.java:310) [18:49:06 WARN]: at com.greatmancode.com.zaxxer.libs.hikari.pool.HikariProxyConnection.prepareStatement(HikariProxyConnection.java) [18:49:06 WARN]: at com.greatmancode.craftconomy3.storage.sql.SQLStorageEngine.setExchangeRate(SQLStorageEngine.java:535) [18:49:06 WARN]: at com.greatmancode.craftconomy3.currency.Currency.setExchangeRate(Currency.java:177) [18:49:06 WARN]: at com.greatmancode.craftconomy3.commands.currency.CurrencyExchangeCommand.execute(CurrencyExchangeCommand.java:33) [18:49:06 WARN]: at com.greatmancode.craftconomy3.tools.commands.SubCommand.execute(SubCommand.java:69) [18:49:06 WARN]: at com.greatmancode.craftconomy3.tools.commands.bukkit.BukkitCommandReceiver.onCommand(BukkitCommandReceiver.java:51) [18:49:06 WARN]: at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44) [18:49:06 WARN]: at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:141) [18:49:06 WARN]: at org.bukkit.craftbukkit.v1_12_R1.CraftServer.dispatchCommand(CraftServer.java:648) [18:49:06 WARN]: at net.minecraft.server.v1_12_R1.PlayerConnection.handleCommand(PlayerConnection.java:1401) [18:49:06 WARN]: at net.minecraft.server.v1_12_R1.PlayerConnection.a(PlayerConnection.java:1236) [18:49:06 WARN]: at net.minecraft.server.v1_12_R1.PacketPlayInChat.a(PacketPlayInChat.java:45) [18:49:06 WARN]: at net.minecraft.server.v1_12_R1.PacketPlayInChat.a(PacketPlayInChat.java:1) [18:49:06 WARN]: at net.minecraft.server.v1_12_R1.PlayerConnectionUtils$1.run(SourceFile:13) [18:49:06 WARN]: at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [18:49:06 WARN]: at java.util.concurrent.FutureTask.run(FutureTask.java:266) [18:49:06 WARN]: at net.minecraft.server.v1_12_R1.SystemUtils.a(SourceFile:46) [18:49:06 WARN]: at net.minecraft.server.v1_12_R1.MinecraftServer.D(MinecraftServer.java:748) [18:49:06 WARN]: at net.minecraft.server.v1_12_R1.DedicatedServer.D(DedicatedServer.java:406) [18:49:06 WARN]: at net.minecraft.server.v1_12_R1.MinecraftServer.C(MinecraftServer.java:679) [18:49:06 WARN]: at net.minecraft.server.v1_12_R1.MinecraftServer.run(MinecraftServer.java:577) [18:49:06 WARN]: at java.lang.Thread.run(Thread.java:748)
And the rates stayed as the first one. Is it possible to do something about that ?
Just to let other people know: I fixed this issue in my fork of CraftConomy3 in this release. @GaburaisuVGC Reported the issue here: pavog#59