Click here to Skip to main content
15,891,704 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
VB
Id  Qty
A   48.17
B   48.52
C   45.44
D   45.76
E   48.12
F   46.48
G   45.23
H   43.89
I   43.93
J   47.34


In above data there are 10 records,i want to select only those records whose sum=227.33
Posted

1 solution

As far as I know, you cannot do this in SQL at all - or if you can it would be hideously complex. It isn't simple in a full programming language which includes arrays, recursion and the ability to build complex structures - which you would probably need to get the result you want.

Don't even try in SQL - do it in your business layer instead.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900