Calculated field question
Post the SQL of the query you now have by opening in design view, click on
VIEW - SQL View, highlight all, copy, and paste in a post.
Include the field name where the 'group of codes having the description
Retail Cost of Sales' are stored (maybe ExpenseCode). Provide a list of the
codes for Cost of Sales.
--
Build a little, test a little.
"WembleyBear" wrote:
I have a query that summarises sales data for a particular month and cost
centre. The data comes from our accounting system and is held in a single
table in my database thus:
tblNominal
------------
CostCode - Long Integer
ExpenseCode - Long Integer
Desc - Text
Current - Double
YTD - Doube
Month - Text
Year - Text
The query sums the Current & YTD values for a particular month, grouping
them by the Description field. This works fine to sum the Sales for say
Retail (which is a group of Expense Codes) but I also want the query to show
the Margin for that type of sale in a neighbouring column. This value is not
held in the table, but could be calculated as there is a group of codes
having the description Retail Cost of Sales, and Retail Margin would be
Retail - Retail Cost of Sales. Is this possible? What would be the best way
of going about this?
Thanks
Martyn
--
Access 2007, Windows XP
|