calculating record

Y

yahooo

Hi all,

let say i have 20 records of payment in descending
order.how can i query a record such that the criteria are:
1.it should be record at 50%of total(which is record#10
for this example)
2.and if there are several records have same payment as
calculated record on point 1, choose the lowest record.
otherwise use only point 1 as parameter.i.e;
record payment
9 $100
10 $100
11 $100
12 $100 >>in this case choose record#12


please help me
 
Top