Re: equivalent for 'compute' in sql server
hi
i think i made you confused. sorry for the inconvenience.
my question is :
COMPUTE is the keyword used in mssql. what is its corresponding keyword in mysql. i.e., keyword that is correspondant to 'compute'. the first query what i had given is the query in mssql i.e.,
CREATE PROCEDURE `pubs_dbo`.`reptq1` ()
select pub_id, title_id, price, pubdate
from `pubs_dbo`.`titles`
where price is NOT NULL
order by pub_id
COMPUTE avg(price) BY pub_id
COMPUTE avg(price) -----------------------in mssql
and i modified it in mysql as :
CREATE PROCEDURE `pubs_dbo`.`reptq1` ()
select avg(price),pub_id, title_id, price, pubdate
from `pubs_dbo`.`titles`
where price is NOT NULL
group by pub_id
order by pub_id -------------------------in mysql instead of using COMPUTE (as in sql).
this query is not giving the same output as the above query gives.
hope, this would make you clear. can you plz help me regd this problem?
thanx in advance.
UJVALA
Subject
Views
Written By
Posted
5380
November 04, 2005 06:16AM
3259
November 04, 2005 09:03AM
Re: equivalent for 'compute' in sql server
3214
November 05, 2005 04:04AM
2848
November 07, 2005 05:21AM
8969
November 07, 2005 06:02AM
4043
November 05, 2005 07:20AM
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.