This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
I have a method which every time it runs, it will add 10 row to my DB but after 3 or 4 times running this file it doesn't add anything to my db. and even it does not throw me any thing like error or ... . I dont know why cuz it works very well for first 3 or 4 times but after ....!
do you have any idea?
and some thing else! after that I can not do any thing in MySQL Command Line Client. seems that it hangs!
I realy dont know what to do!
first check the loop; is it your real code ? then loop is here <5 increase it to <10 and please follow the James Ward update code of static connection method..
Joined: Mar 22, 2005
James Ward wrote:
if "conn" is declared at class level, then why is it declared again here? Furthermore, getConnection does not return a connection - it's declared void. Let's not confuse the issue by posting non-working code.
Joined: Jul 06, 2009
OOh my god! Dear friends specialy James Ward and Ulf Dittmer Thank you sooooooooooooo much!. I just change a little things void--> Connection and now it works!!!