Pratap Reddy

Ranch Hand
+ Follow
since Jan 05, 2001
Merit badge: grant badges
For More
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 Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Pratap Reddy

I am writing one application where the requirements like this,
User will enter the telephone and presses search button then
there could be more then one person with same telehone number.
I am useing border layout, in north user enters telephone
number and in center the result from data base need to be
displayed. Can some body suggest me some solution for this or
may be alternative solution welcome.
Advance Thanks

23 years ago
Even I got this problem but when I removed close() method It solved. But not sure down the stream. Check this might help you.
Hi Thomas Paul,
With you suggestion I changed accordingly but this different error message "Column not Found". But I tried using dynamic SQl as follows it is working fine.

Using the above method I am able to get my requirements.
But Thanks for Help.
String s = "kpreddy";
String query = "SELECT UserId FROM Security WHERE UserId =" + s;
PreparedStatement stmt = dbconn.prepareStatement(query);
ResultSet rs = stmt.executeQuery();
When I run this queary I get too few parameters. Please tell me
how to pass a host variable to select queary.
Thanks In Advance.
I agree with sai what he said is right. Since there is reference
to O object. In that case O is not eligible for Garabage collection.
In second case X is eligible to Garbage collection. My assigining null to X object you are removing the reference so It has to be
eligible for Garbage collection.
Hi Shah,
I don't belive its right, I got some questions on
GridBagLayout. I do belive that CardLayout not in objective. Rest I am not sure. Check this site for
upto date Objectives for Java 1.2
Hi Nitin,
Here is the url for Sun threads concepts. You are right there is no way to perdict 100% correct answer. It all depends on OS system.
It might be peemetive or timeslice.
Sun Certified programmer for Java 1.2
Hi Nitin,
Change all IF to WHILE loop. Then every thing will work
Hi Nitin,
Let me try to explain , Thread 1 once complete the
synchronized method then automatically releases the lock.
Your thinking will be right if you use some wait() and
notifyAll() methods. While Thread 1 put's numbers Thread
2 need to wait(). Once Thread 1 completes all put's
method then notifyAll(), then Thread 2 will start
Hi Shashank,
There is no way to find gc'd. Since they are stored on heap. Only objects which created on heap are gc'd. Or else all objects created with new keywords are gc'D.
Hi Suman ,
Rules of overriding is you can't make the method much
Private ---> friendly ---> protected ---> public.
But in your example public void sample() is overriding with void sample(). That not possible. It gives compiler error.
Duration is 120minutes. You can change your answers as many times you want within stipulated time.

Since single char takes 2 bytes and total bytes written should be
be 6 bytes. But it prints only 4 bytes.?
[This message has been edited by Pratap Reddy (edited March 07, 2001).]
Hi All,
Today I became Sun Java Certified person with 76%. Here is my impression regarding my exam,
Bottom line the exam is tricky rather then tough. JavaRanch discussion form did particularly helped me a lot in achieving this score. Hat's off to all participants of Javaranch people.
I did go through lots of exam papers but believe me, all not up to standards. Some exam papers mislead you. So whenever you do some practice exam write some code and test it, before you lay your fundamentals.
In my view RHE and Khalid where good books and apart from this Marcu's green papers and javranch discussion form.
23 years ago
Thank you John ...I know what you are trying to say. Now I am clear.