Solved

Dynamicaly sizing two dimensional array?

Posted on 2004-04-23
2
181 Views
Last Modified: 2010-04-01
Is there anything that would be equivalent to a dynamicaly sizing two dimensional array?

I want to read a database resultset into something that I can return....
0
Comment
Question by:chambers777
2 Comments
 
LVL 9

Expert Comment

by:Nick_72
ID: 10902289
You could use a Vector, which you can size dynamically, and in each Vector element you store another Vector.

/Nick
0
 
LVL 7

Accepted Solution

by:
searlas earned 50 total points
ID: 10907731
More generally, return a List of Lists, choosing the implentation most sutiable wrt synchronization (Vectors are synchronized - i.e. thread safe, ArrayLists are not)
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
stateless EJB with glassfish 2 73
project group option in netbeans equivalent term in eclipse 1 51
java cigar challenge 58 214
login form jsp example 2 37
Many businesses neglect disaster recovery and treat it as an after-thought. I can tell you first hand that data will be lost, hard drives die, servers will be hacked, and careless (or malicious) employees can ruin your data.
There's a lot of hype surrounding blockchain technology. Here's how it works and some of the novel ways it' s now being used - including for data protection.
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

828 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