Can I use Set instead of List?

2009-04-05 Thread fer knjige
Hi, I have a simple query: select * from Products. I want to have results in Set not in List. How can I do it since method 'queryForList' returns only List? Thanks in advance!

Re: Can I use Set instead of List?

2009-04-06 Thread fer knjige
Unfortunately this doesn't work. It returns following error: Exception in thread main java.lang.ClassCastException: java.util.ArrayList. Solution? 2009/4/6 Larry Meadors larry.mead...@gmail.com return new LinkedHashSet(queryForList(...)); Larry On Sun, Apr 5, 2009 at 10:53 PM, fer knjige