Solved

Using Database Indices Effectively in JAVA

Posted on 2008-06-12
3
160 Views
Last Modified: 2010-03-30
Hi Experts,

My application is built in Java and the back-end is Oracle Rally installed in a Thin Server. To maximize the performance, the Database is being indexed now.

I got little information from the DBA. He says it uses Sorted indices for range retrieval and hashed for direct look-up. He has also provided me the following information about the indices.

INSURED_INFO_0400_SORTED        with column WIP_NUMBER
                                and column LAST_NAME
                                and column MIDDLE_NAME
                                and column FIRST_NAME
                                and column SSN
                                and column BIRTH_DATE
 

INSURED_INFO_HASH               with column WIP_NUMBER
        in INSURED_INFO_AREA
*********This index is a placement index clustered with the data*************

INSURED_INFO_HASH_SSN           with column SSN
                                and column WIP_NUMBER
                                and column INSURED_SEQUENCE_CODE

 
INSURED_INFO_SORTED_001         with column LAST_NAME
                                and column FIRST_NAME
                                and column WIP_NUMBER


I would like to know, how effectively and efficiently we could make use of the indices in the Java application.

Please advice.

Thanks & Regards,
Madhu Manikandan, R
0
Comment
Question by:CIPL-Senthil
[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
  • 2
3 Comments
 
LVL 25

Expert Comment

by:Tomas Helgi Johannsson
ID: 21780070
     Hi!

If you want Oracle to use the indexes you create a sql query
where the columns of the indexes are used as the matching columns
in where clause of the sql query.

If Oracle ( or any other database) cannot match the sql where clause columns
to a index column it will use table scan instead of index scan.

Regards,
  Tomas Helgi
0
 

Author Comment

by:CIPL-Senthil
ID: 21784057
Our backend is ORACLE RALLY [OLD VERSION]. I would like to know whether the indices created in oracle rally could be used effectively in JAVA. If so, could you please provide an example?
0
 
LVL 25

Accepted Solution

by:
Tomas Helgi Johannsson earned 500 total points
ID: 21784748
     Hi!

It should not matter what version of Oracle or what database it is as long as the indexes match
the where clause columns as I said before.

Regards.
   Tomas Helgi
0

Featured Post

How our DevOps Teams Maximize Uptime

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us. Read the use case whitepaper.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
use lov values 2 72
SHA2 certs for IIS AND Java? 2 122
Facing this issue for maven proxy setting 2 27
Tomcat 9 + java 8 error while trying to deploy a war file 2 723
I had a project requirement for a displaying a user workbench .This workbench would consist multiple data grids .In each grid the user will be able to see a large number of data. These data grids should allow the user to 1. Sort 2. Export the …
Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
This video teaches viewers about errors in exception handling.

726 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