Click here to Skip to main content
15,907,183 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i have bidhistory table and in that table there is one field named bidprice . i want fill bid price in gridview like when product 1 has 5 bid price so where price is lower and unique one i wanna get this row. how i do this?please help me
Posted

1 solution

Try this code to get your solution:

SQL
create table Bidhistory
(
  bidid int,
  bidprice int
)
insert into Bidhistory values(1,100);
insert into Bidhistory values(1,50);
insert into Bidhistory values(1,100);
insert into Bidhistory values(1,50);
insert into Bidhistory values(1,75);

select distinct MIN(bidprice) from Bidhistory


Output:

50

and then try to bind it gridview
 
Share this answer
 
v2

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