- Strength to Increase Rep
- +16
- Strength to Decrease Rep
- -4
- Upvotes Received
- 401
- Posts with Upvotes
- 351
- Upvoting Members
- 141
- Downvotes Received
- 45
- Posts with Downvotes
- 44
- Downvoting Members
- 26
Application Developer and Software Architect
Re: executeUpdate returns an int indicating how many rows were affected by the query. It does not return a resultset. So, on the line where you are carrying out an executeUpdate, you should not be expecting a ResultSet as the return value. | |
Re: A bit of game (and there are better ways, to be sure) but, parse it as an int (I know it's the wrong value, but bear with me), get the binary value of that int, lop of the left most bit (the string will only contain enough bits to represent … | |
Re: Manual. Gives full control with no "bolierplate", repetitive, rigid code. But that's not what you're looking for is it? I dislike [i]all[/i] "Gui builders", as they all produce rigid, reptitive code that is hard to modify correctly, and is not always that effecient when any action to be performed is … | |
Re: The same way you do in HTML, since all a JSP (or actually a Servlet judging by what you posted) does is produce HTML (not that you "call" css, at all, you reference it). Of course you have to escape the quotes that appear within the quotes. | |
Re: Why are you doing System type stuff using Java? It is not designed for it. If you want a command line command to get the "application" list that appears in TaskManager, then why are you asking in a Java forum? Ask in some Windows forum somewhere. Edit: And this is … | |
Re: Sorry, but you do realize that that only investigates the first element in the list, right? | |
Re: [url=http://www.lmgtfy.com/?q=Java+Custom+Cell+Renderer]here[/url] | |
Re: Hey James, Dani. Glad to hear it. I no longer have much time to look in here, but glad to see it is still around, and still willing to take, and act on, user input. | |
Re: Simply modify your query. "SELECT contact, start FROM appointment WHERE createdBy = ? and start >= ? and start <= ?" // and use ps.setString(1, MainApp.currentUser); ps.setString(2, new Date()); ps.setString(3, new Date(new Date().getTime() + (1000 * 60 * 15))); // 1000 millisecond * 60 seconds * 15 minutes = number … | |
Re: That parse method is giving you a java.util.Date object, you need a java.sql.Date object in the setDate method. See the Date(long) constructor of java.sql.Date and the getTime() method of java.util.Date and use the latter as the argument in the former to get a java.sql.Date instance. Edit: P.S. it would have … | |
Re: [inlinecode]find /path/to/directory -type f -mtime 61 -exec rm -f {} \;[/inlinecode] 61 (days) works for everyting except it is one day short for July August and 1 to two days long for (January/February) / (February/March). Edit: make it 62 if it absolutely must be every last day for two months. … | |
Re: If the only thing in the file is filenames simply do rm `cat input.txt` if there is more than just filenames, but say the third word of every line is a filename then do the following: rm `awk '{print $3}' input.txt` (the fourth word would be $4, etc) | |
Re: It's [i]not[/i] an "apache setting". It is a "Web Container"/"Application Server" configuration. I.E. Tomcat, Glassfish, Sun Application Server, WebSphere, WebLogic, JBoss, Jetty, etc. Find out which one you are going to use and read its documentation. | |
Re: Eww, that with the notification email could also turn out to be a windfall for the hackers. What's to stop them from sending a phishing attack (although that is not really necessary, but could also give them the "new" password) or trojan email using that as the bait? | |
Re: [QUOTE=bloody_ninja;655019]I haven't seen any tutorials for JSP , so I guess I will post this one link that I found. [URL="http://www.visualbuilder.com/jsp/tutorial/pageorder/1/"]http://www.visualbuilder.com/jsp/tutorial/pageorder/1/[/URL][/QUOTE] [url]http://java.sun.com/j2ee/1.4/docs/tutorial/doc/[/url] [url]http://java.sun.com/javaee/5/docs/tutorial/doc/[/url] | |
Re: Yes. Write a Comparator. (see the API docs for Comparator and the Collections Tutorials) | |
Re: wordMap.put(word, wordMap.get(word)++) | |
Re: You don't, you create executable jar files (not "exe"s). [url]http://java.sun.com/docs/books/tutorial/deployment/jar/index.html[/url] Edit: And, if you want a "real exe" (i.e. a native executable), then use a language designed to produce a native executable (which Java is not). If you insist on doing something that will negate all the "advantages" gained by … | |
Re: Because you have mangled your url. See the [url=http://download.oracle.com/javase/tutorial/jdbc/index.html]tutorials[/url]. | |
Re: I'm not certain, but I think you are simply hitting up against some "minimum size" type restrictions. As you can see the orange (dark yellow?) square is the same size as the green and yellow squares and it's relation to the red square has become even more skewed than the … | |
Re: SYOT Start your own thread and clearly state your problem and post both your code (or at least a small self-contained example that reproduces the problem) and any and all error messages. | |
Re: Closing this abused zombie now. | |
Re: Um, check if Arial exists and if not set something else? | |
Re: First, ensure a garbage collection is done, then see if it is reduced, at all. Other than this, java will only return memory to the system if a certain percentage of the heap space is "free", there are command line parameters to use increase/decrease these ratios, but I suggest caution. … | |
Re: [QUOTE=mr.sweetchuck;333254]Hi, I'm trying to use the replace() method to take out all instances of " " , (space) with an underscore, ("_"). I'm doing this because I'm using URLs to connect to a servlet. I keep getting this error: replace([b]char,char[/b]) in java.lang.String cannot be applied to ([b]java.lang.String,java.lang.String[/b]) [code] url.replace(" ", … | |
Re: Google for JUnit and design unit tests, and then do extensive "business" tests as well. And then you will know that your program is as good as you are currently able to test it for, but some user will STILL find bugs (and you can only hope it isn't a … | |
Re: traverse the directory and remove all sub directories, and all sub directories of the sub directories, etc, a recursive method will suffice. | |
Re: Use Boolean not boolean. | |
Re: Well, don't use scriptlets. Either use a Bean, or google for the sql jstl tag package. |