Query problem
Posted: Sun Mar 22, 2009 3:58 am
Hi
I am having problem is selecting non high bids. For example user id 5 made 2 bigs on a product id 20 and both are smaller than the highest bid that is posted by a user id 22. Now I want to select that product for whom user id 5 did not made highest bid.
Thanks
Here is my db table structure:
I am having problem is selecting non high bids. For example user id 5 made 2 bigs on a product id 20 and both are smaller than the highest bid that is posted by a user id 22. Now I want to select that product for whom user id 5 did not made highest bid.
Thanks
Here is my db table structure:
Code: Select all
CREATE TABLE `bids` (
`PK_ID` int(11) NOT NULL auto_increment,
`FK_USER_ID` int(11) default NULL,
`FK_PRODUCT_ID` int(11) default NULL,
`bid_price` float(11,0) default NULL,
`created_on` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
PRIMARY KEY (`PK_ID`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=22 ;