Last post Jul 04, 2017 05:36 AM by Deepak Panchal
Jul 03, 2017 05:31 PM|krvish94|LINK
I am developing a website in asp.net. I have a database table called Bid. In this table, column pid is foreign key and id is primary key. I also have price column. I want to write a query where i want to get all the columns where id=pid and i want the max(price)
for the price associated with pid. Any help is appreciated thanks in advance.
Jul 04, 2017 05:36 AM|Deepak Panchal|LINK
I try to create a sample table with some dummy data.
select id,pid,max(price) over (PARTITION by pid) from bid where id=pid order by price desc