Solved

JSP and JDBC paging proble

Posted on 2004-08-10
7
971 Views
Last Modified: 2013-11-24
I am converting several .asp files to .jsp.

As you know, ADO provide paging function for displaying data page by page.
However, Does JDBC support this function?
Or Can you tell me how can I implement that in JSP?

By the way, would you tell me how can I translate the following ASP statements to JSP?

Request.ServerVariables("http_url")
Request.ServerVariables("url")

Here is my environment:
DataBase server:Microsoft SQL Server2000
web server:tomcat 4.1.29
JDK:Sun Micro JDK1.3
0
Comment
Question by:cstsang
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 
LVL 35

Expert Comment

by:girionis
ID: 11761417
Check this out: http://jsptags.com/tags/navigation/pager/ it is a tag library that helps you do paging.

>By the way, would you tell me how can I translate the following ASP statements to JSP?
>
>Request.ServerVariables("http_url")
>Request.ServerVariables("url")

Can you tell us what they do in ASP?
0
 
LVL 7

Author Comment

by:cstsang
ID: 11762321
Please refere:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/iissdk/iis/servervariables.asp

In most case, their the same.
However, when the user browse the root directory of web site, they different.

For
Request.ServerVariables("http_url"),
it return "/index.asp"

For
Request.ServerVariables("url"),
it return "/" only.






0
 
LVL 35

Expert Comment

by:girionis
ID: 11762368
It seems that it redirects me to this:

http://msdn.microsoft.com/library/shared/deeptree/bot/bot.asp?dtcnfg=/library/deeptreeconfig.xml

Can you tell me very briefly what they do?
0
Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

 
LVL 7

Author Comment

by:cstsang
ID: 11768416
HTTP_URL=>Returns base portion of the URL (same as UNENCODED_URL).

URL=>Gives the base portion of the URL.

0
 
LVL 35

Expert Comment

by:girionis
ID: 11769947
Try to use:

request.getRequestURI()

If this is not what you want then take a look here: http://java.sun.com/j2ee/sdk_1.3/techdocs/api/javax/servlet/http/HttpServletRequest.html and see if any of the methods help you.
0
 
LVL 7

Author Comment

by:cstsang
ID: 11770118
Ok!
I will try this command.
By the way,I downloaded the WAR file from  http://jsptags.com/tags/navigation/pager/ ,
however I don't understand the sample code.
It is because the sample code using array (not a resultset) as a datasource.
Would you give another sample code(which is using resultset) to me for reference?

thank you very much
0
 
LVL 35

Accepted Solution

by:
girionis earned 50 total points
ID: 11770150
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Java Flight Recorder and Java Mission Control together create a complete tool chain to continuously collect low level and detailed runtime information enabling after-the-fact incident analysis. Java Flight Recorder is a profiling and event collectio…
In this post we will learn how to make Android Gesture Tutorial and give different functionality whenever a user Touch or Scroll android screen.
Viewers learn about the “while” loop and how to utilize it correctly in Java. Additionally, viewers begin exploring how to include conditional statements within a while loop and avoid an endless loop. Define While Loop: Basic Example: Explanatio…
This tutorial explains how to use the VisualVM tool for the Java platform application. This video goes into detail on the Threads, Sampler, and Profiler tabs.
Suggested Courses

627 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question