Hello,
I want a small help in Criteria Queries.
e.g. my database table is like following
Primary-Key Column : Column-1 : Column-2 : .... : Column-N
1 : : 100 : ... : anydata
2 : 1 : 101 : ... : anydata
3 : : 100 : ... : anydata
4 : 2 : 101 : ... : anydata
5 : 3 : 102 : ... : anydata
6 : 4 : 103 : ... : anydata
7 : : 100 : ... : anydata
8 : 5 : 101 : ... : anydata
I want to narrow my result set based on two columns of the dataset.
first i am getting all valueobjects where column-1 is not null. (i.e. PK 2,4,5,6,8)
now for all of these not null rows i want only those rows when column-2 values are different. i.e. out of 2,4,5,6,8 column 2 values are same for 2,4 and 8 so i want any one of them not all.
is there any way I can add Restriction in my criteria query?
I hope you will understand the problem and will get any solution.
_________________ Tapan Maru
|