473,386 Members | 1,609 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

when we have to write the DataBase connectivity in Jsp Page

kaleeswaran
132 100+
hi!
lost month i was attend one interview,,,
they asked me questions like :what Scenario we are using Database connection in jsp .
but i don't know the answer..
can you tell me the answer?...
Thanks
Kaleeswaran
May 7 '08 #1
2 1174
ajos
283 100+
hi!
lost month i was attend one interview,,,
they asked me questions like :what Scenario we are using Database connection in jsp .
but i don't know the answer..
can you tell me the answer?...
Thanks
Kaleeswaran
IMHO, we should never use database connection in jsp page if possible. It should ideally be in a servlet/class. Its about best practises, as for your question, i've never used a db connection in my jsp page(and i intend to keep it that way).

regards.
May 7 '08 #2
Whenever you want to retrieve the data from the database and make your site dynamic ..HFor ex.. you are making an application which books ticket online.. then you have to use the database
May 27 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

11
by: HolaGoogle | last post by:
hi all, can you please tell me what i should do to avoid session timeout when displaying my database info in my asp form (DisplayUserDatabase.asp)??? ** actualy it does load and display the...
1
by: harish | last post by:
I am using java applications to connect to my MS SQL Server database. I am using ODBC for database connectivity. If i am running my java applications in a remote PC and try to connect to database...
1
by: lhansen | last post by:
I've seen posts similar to this, but have not found the magic bullet to solve my problem.. I have an asp page (see source code below) running on IIS 6.0 on Win2003 Server that tries to get file...
2
by: jbmccluskey | last post by:
I'm a newbie so please be gentle. In attempting to run a restore I get the following error message: "Exclusive access could not be obtained because the database is in use." However, it doesn't...
1
by: u473 | last post by:
I need to go over the hurdle of the connectivity syntax of ADO vs DAO. I want to loop thru each record of table "A" in the current database "X" If condition is true in field "Y" modify field...
8
by: Galina | last post by:
Hello I have 6 dependent list boxes on my ASP page:  Faculty;  Lecturer;  Course;  Course occurrence;  Group;  Week commencing date. When faculty is selected, lists of lecturers and...
0
by: tony dong | last post by:
Hi there I use vs.net 2005 with standard sql 2005 under machine\sql2005 for instant when I create webpart, the code get from quickstart as follow: <%@ Page Language="C#" %> <%@ Register...
3
by: jc | last post by:
Hi there: Reading from internet i found that the best way to use a database is to connect and disconnect on every single database request, so if you are loading a listbox manually from a...
1
by: khalfan | last post by:
Assignment Objectives: The objective of this assignment is to design and develop a dynamic web site application with the use of ASP to create a database and manipulate the information. ...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.