Dave Tolls

+ Follow
since Sep 04, 2013
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Rancher Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Dave Tolls

Does your web service have any logging?
If so, what does that show?
If not, then it might be an idea to add some.
2 days ago
Do you see any errors in the logs?
2 days ago
Can you show the full stack trace, and show the code around the line throwing that exception?
2 days ago
You're actually creating two games, and only one of them has theNumber initialised...and the other one is the one being displayed (so theNumber is still stuck at zero).

The first is here:

and the second (that actually gets displayed) is here:

Remove the first code and stick it where the second one is (along with a setVisible call).
3 days ago
Have you tried debugging the javascript and seeing what has been returned from the call?
Also, look at whether anything has been added to the structure of the page.
You'll need to use your browser's developer tools for this (F12).
1 week ago

Dana Ucaed wrote:ROL is my currency.

I live in Roumania.

ROL is the old currency.
RON is the current one.
And I don't see either of them using the currency format shown above.
1 week ago
I think those posts are referring to using something like a new Connector/J with a really old MySQL.
So, in this case, using Connector/J 8 with pre-MySQL 5.5.

From the page for Connector 8.0.11:

It is suitable for use with MySQL Server versions 8.0, 5.7, 5.6, and 5.5.

So it should be fine, assuming everything is as the OP says.

Peter Baumarchais wrote:

Why would you need more that 2.1 billion decimal places?

Because you might.  Because of reasons that people don't speculate on, because
of a situation which is outside of people's minds.  That's why.

There's lots of things that some people might want to do with a language, but that doesn't mean a language has to cater to that.

Java is very much a general purpose language, so expecting it to handle things that are more specialised is probably asking more than it is likely to ever provide.
1 week ago
Depends what the server is expecting.
The current payload for the POST is perfectly valid JSON, and a perfectly valid payload.
1 week ago
It's happening because a database will generally provide a rolback space, since until to commit you are allowed to roll back the command.

If you are certain there is no need to rollback then is there a truncateTable method?
TRUNCATE will normally just strip out the rows, and not DELETE them.
1 week ago
Or use a PreparedStatement.
That way you won't get errors with quote marks.
Is that the total of the error?
Normally it would give a form of stack trace so you can narrow down which native call is causing the problem.
1 week ago
There's no issue with a return statement in a try/catch block.
It's prefectly valid, and has no effect on the flow.
A finally block will always execute before the try/catch/finally block exits.

My first thought is that I'm surprised that doesn't throw an error.
Maybe MySQL takes the values of the current row (whatever that might mean in this case), which would be nulls in this case?

In any case, if you were expecting the SQL to understand that the given values are actually Java variables in your Java app then that is not going to happen.

You have your Java app.
That sends a SQL call to MySQL.
MySQL knows nothing about where that call comes from, only that it is a valid user.
The SQL sent has to be something you could actually execute by hand on MySQL (via the command line or a MySQL IDE), though in the case of JDBC PreparedStatements the variable binding syntax may be slightly different.