This week's book giveaway is in the Artificial Intelligence forum.
We're giving away four copies of Pragmatic AI and have Noah Gift on-line!
See this thread for details.
Win a copy of Pragmatic AI this week in the Artificial Intelligence forum!

Tim Moores

Saloon Keeper
+ Follow
since Sep 21, 2011
UK / DE
Cows and Likes
Cows
Total received
117
In last 30 days
2
Total given
11
Likes
Total received
899
Received in last 30 days
38
Total given
352
Given in last 30 days
14
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Tim Moores

tangara goh wrote:The names 'Zara Ng' there was a space for sure.



That's irrelevant. You need to pay close attention to detail - that's a crucial aspect of programming. I said:

Tim Moores wrote:The problem is a missing space between two names.



and in particular:

Tim Moores wrote:There seems to be a space missing between "project.tutor" and "tutorName".



So the names in question are attribute names.

tangara goh wrote:I have put the 'tutorName' on the 2nd line with a 'prefix' + to indicate a continuation.


That's not what the problem is. The problem is a missing space between two names.

May I know the Parentheses are referring to the ( right after VALUES ? and end with a ) ?


Those aren't the parentheses I was talking about. I specifically said "around the list of actual values", not "around the list pf parameter names". You should read up on the syntax of Insert statements to learn how they look like.

Dave Tolls wrote:log the SQL you are producing in your code so you can then execute it directly into the database.


+1
Why don't you start by telling us what your answer would be. If you're unsure, start with working through Syntax_(programming_languages) and Semantics_(computer_science).
1 day ago
1) There seems to be a space missing between "project.tutor" and "tutorName".

2) There's a " instead of a ' before Sunrise.

3) Parentheses are missing around the list of actual values.
Welcome to the Ranch.

What is "a source"? What does subscribing/paying have to do with it? Who would pay whom for what?
I'm just trying to make the point that files - when created in this way--do not have styling. I'm not sure that this is clear to the OP, and wanted to make sure.
1 day ago

unless we're talking about a fixed width font, which .txt files usually are.


That is a feature of the viewer application. The file itself -which is being created here- can't do anything about that.
2 days ago
Text files have no formatting. You could add spaces in front of the title to move it right, but whether that moves it exactly into the center depends on the font type, the font size, and the page size. It'll likely not come out the way you want it to, so you may be better off focusing on something else.
2 days ago
As regards personal data, you need to adhere to applicable law (like GDPR), no matter where the data is stored.
2 days ago
Web apps need a servlet environment to run; a command line will not do. For unit tests involving servlet code you may get away with mock objects.

But let's take a step back: how can trying to debug an issue with a web app take a whole month? If the debugger built into the IDE (assuming you're using one) is too cumbersome, try a standalone one like JSwat. I've been using that to debug apps running on Tomcat, and it works fine.

The JDBC issue means the JDBC driver is not in the classpath. You need to include the appropriate jar file in whichever way is appropriate for however you run the code. If that's on the command line, something like "java -cp .;mysql-connector-java-5.1.47.jar JDBCExample" might do the trick.
3 days ago
Sounds like an exercise you should be doing in order to learn something. So: what do you have so far, and where are you stuck making progress? If you haven't started yet, what ides have you had?

Have you worked through the Java networking tutorial yet? If not, start with that.
I really don't understand why people think that Java won't be free any more. I thought Oracle's document was pretty clear on that, and on the difference between Oracle's JDK and OpenJDK.
3 days ago
Not here. But you can embed YouTube and Vimeo videos in posts.
3 days ago

Tim Moores wrote:The bottom line is: don't pass null arguments to Integer.parseInt - check the values before using them.


Or in case of "java.lang.NumberFormatException: For input string: "" " : don't pass empty strings to Integer.parseInt.
4 days ago
This is the important part:

Caused by: java.lang.NumberFormatException: s == null
        at java.lang.Integer.parseInt(Integer.java:570)
        at java.lang.Integer.parseInt(Integer.java:643)
        at com.floatr.cypher.MainActivity.onCreate(MainActivity.java:72)



The line number and class name don't match the code you posted earlier, so we can't pinpoint the issue. But it's in line 72 of your MainActivity class. The bottom line is: don't pass null arguments to Integer.parseInt - check the values before using them.
4 days ago