MySQL Forums
Forum List  »  Microsoft SQL Server

Re: Query Conversion MS to MYSQL
Posted by: Sean Nolan
Date: April 12, 2005 10:04AM

MySQL versions earlier than 4.1 do not support subqueries. You can probably make that work with a join and grouping, something like this

Select CARTS.CARTNUMBER, CARTS.UNITPRICE, QUANTITY = SUM(selitems.numitems)
from carts
INNER JOIN selitems ON SELITEMS.CARTNUMBER = CARTS.CARTNUMBER
GROUP BY CARTS.CARTNUMBER, CARTS.UNITPRICE

Sean Nolan

Options: ReplyQuote


Subject
Written By
Posted
Re: Query Conversion MS to MYSQL
April 12, 2005 10:04AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.