Access 2003
Need to query total quotes by salesperson for a particular time period, my query has the following syntax:
So I have a complete count of all quotes in the table, I have a form with two textboxes that the date range is inputted, but with the above query if I put a date range in then the count is by day. I also need to calculate the average quotes per month by entire sales department, minus the highest and lowest quote amount.
Need to query total quotes by salesperson for a particular time period, my query has the following syntax:
Code:
SELECT api_tblQuotes.Salesperson AS SalesID, user_tblSalesmanProp.Description AS Salesman, Count(api_tblQuotes.[Quote#]) AS [CountOfQuote#], api_tblQuotes.QuoteDate
FROM user_tblAccountProp INNER JOIN (user_tblSalesmanProp INNER JOIN api_tblQuotes ON user_tblSalesmanProp.ID = api_tblQuotes.Salesperson) ON user_tblAccountProp.ID = api_tblQuotes.Acct
GROUP BY api_tblQuotes.Salesperson, user_tblSalesmanProp.Description, api_tblQuotes.QuoteDate;
So I have a complete count of all quotes in the table, I have a form with two textboxes that the date range is inputted, but with the above query if I put a date range in then the count is by day. I also need to calculate the average quotes per month by entire sales department, minus the highest and lowest quote amount.