Jump to content

Recommended Posts

Posted

Does anyone know how to do calculated fields based on the results of a query?

I have a car sales database . In the database we have created a multiple table query that displays which cars each sales person has sold.

So if Sales Person 1 has sold 3 cars at £1500 + £2000 + £2532 then I need to add that up into a new field and display it on the report.

I know how to add up different fields, but not how to add up the results of the query - which are all based in different records but the same field.

Any help appreciated.

Gareth

Posted

You need to do a JOIN query on the salesman table and the sales table.

 

You can get the total of the sales with

 

SUM([sales].[sales value]) AS TotalValue

 

Does that make sense?

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...