I think he wants the sum as you shown below, but needs to group the month and year if he wants those with his sums. Remember - when you use the aggregate functions in X++ the query won't fully populate the other columns - only the columns mentioned in a group by or with an aggregate function will get populated. And - columns with aggregate functions get the resulting value stored in column of the same name. (So the value of sum(qty) below will be accessed by <tablename>.qty not <tablename>.sumqty or something similiar)
--- On Mon, 8/18/08, vamsi praneeth <[EMAIL PROTECTED]> wrote: From: vamsi praneeth <[EMAIL PROTECTED]> Subject: Re: [development-axapta] How To Sum To: [email protected] Date: Monday, August 18, 2008, 10:19 PM I have no idea about month and year....coz i didnt understand what you actually want. But for the sum part it is like Select sum(qty) from <tablename> group by <fieldname>; print <tablename>. qty; pause; From: hendAly unes <[EMAIL PROTECTED] co.uk> Subject: [development- axapta] How To Sum To: development- [EMAIL PROTECTED] ps.com Date: Sunday, August 17, 2008, 12:17 PM Dear All I want Help in sql statment in Axapta iwant to Select Statment For Excmple select Sum(Qty) As Qty,Month( Date)As Month , Year(Date)As Year From Table 1-How To Convert This Sql Statment To Sql Statment In Axapta 2- Any Books To Help Me In Just Sql Statments Thnaks Send instant messages to your online friends http://uk.messenger .yahoo.com [Non-text portions of this message have been removed] [Non-text portions of this message have been removed] [Non-text portions of this message have been removed]

