Hi Yogesh,
    I would use vector instead of HashTable for this particular problem.
Gargi

Yogesh Agarwal wrote:

> Hi all,
>
> In my servlet I am trying to retrieve all the data from the database in the
> init( ) itself ,store the values in a Hashtable and close the connection, so
> that I dont have to make or break connection every time I want to query the
> database. Then I can use the stored data.
> My problem is that when I have a key-value pair like code - name, it works
> fine. But I retrieve all employee_code and project_code (var names) from the
> data base for a particular Date. Now I want to get all the employee_codes
> for a particular project_code. I have figured out that Hashtable is not the
> right data structure for this purpose. If somebody could guide me on this
> matter, it would be of great help.
> Thx in advance
>
> Yogesh Agarwal
> Software Engineer
> IMRGlobal Corp.
> #22, SEEPZ, Andheri(E),
> Mumbai - 400 096
> Phone : 91-22-8291421  Ext 151
> Mail to : [EMAIL PROTECTED]
>
> ___________________________________________________________________________
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff SERVLET-INTEREST".
>
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources: http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to