File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JSP and the fly likes Questions Asked at interview Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "Questions Asked at interview " Watch "Questions Asked at interview " New topic

Questions Asked at interview

swathi reddy

Joined: Jul 03, 2006
Posts: 1
1)Can we pass colletions through callable statements? If yes how?
2)How do you store Pictures and text files in java?
3)After servlet generation of Jsp which life cycle methods will be generated?
4)Difference bet Resultset and Rowset?
5)Does Jsp supports caching? if yes how?
6)can we deploy an Enterprise application in Tomcat? If yes how?
7)Jsp is single threaded or multithreaded?
8)In base class if you are using one exception, is it possible to use super class of previous exception in child class?
9)BMP or CMP which is better?How?
10)Suppose you are performing operations with 2 databases and one database fials how will you rollback the transaction?
11)Where can i download Tomcat and java software?
[ July 03, 2006: Message edited by: Bear Bibeault ]
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63844

What are your answers?

[Asking smart questions] [About Bear] [Books by Bear]
Santhosh Kumar
Ranch Hand

Joined: Nov 07, 2000
Posts: 242
1. Not sure if you can pass Collection to callable statement.

2. Not clear what you mean by "in Java". If you meant, how do you store picture and text files in the file system using java then; use (or other streams) for pictures and (or other writers) for text.

3. There are basically three lifecycle methods in Servlets. init(), service() and destroy().

5. Jsp as technology itself, does not support caching.

6. If your enterprise application consists of only Servlets and Jsps, yes you can. If it contains ejbs, mdbs etc, then you cannot. (

7. By default jsp is multi-threaded (meaning multiple threads would execute the jsp code simaltaneously). If you added directive <%@ page isThreadSafe="false" %>, then container ensures that only one thread execute a jsp's servlet object.

8. No.

9. If bmp would always be better than cmp or otherway, then sun would not have created underperforming technology at all. Depending on the scenario, both has pros and cons.

10. Use xa drivers which supports transactions across the dbms systems.

11. and
Christophe Verré

Joined: Nov 24, 2005
Posts: 14688

11)Where can i download Tomcat and java software?

Who would ask this at an interview ? !!
I'd reply

[My Blog]
All roads lead to JavaRanch
Ulf Dittmer

Joined: Mar 22, 2005
Posts: 42965
Who would ask this at an interview ? !!

I agree, these are strange questions to ask in an interview. Most of these can be answered easily within a few minutes given access to the API docs, the specifications and Google. The fact that an applicant remembers these is testimony of a level of basic experience, and of a memory for facts, but doesn't tell an interviewer much about his grasp of underlying concepts. The only one of these I might ask is #9, and pity the poor applicant whose answer favors one over the other instead of saying "it depends".
[ July 04, 2006: Message edited by: Ulf Dittmer ]
Pradeep bhatt
Ranch Hand

Joined: Feb 27, 2002
Posts: 8927

1)Can we pass colletions through callable statements? If yes how?

It should be possible to pass Arrays. I have tried this with Oracle database. Well may be a proprietary call.
[ July 04, 2006: Message edited by: Pradip Bhat ]

I agree. Here's the link:
subject: Questions Asked at interview
It's not a secret anymore!