H
HubbyMax
I am setting up an inventory program that requires a monthy billing report
that shows each departments totals for products ordered and what their monthy
charge is. This report must be divided by each department. Currently it says
there is a problem in the "FROM" line but has also said there is problems in
the "INNER JOIN" areas. My Database properties for this form is as follows.
The report is accessed by a date peramiter box;
SELECT DISTINCTROW Products2.StockNu, Products2.ProductName, Dept2.Cust2,
Dept2.DeptName, [Products2].AvgUnitPrice AS [Avg Unit Price],
Sum([Req1].QuantityIssued) AS [Total Units] FROM Products2 INNER JOIN (Dept2
INNER JOIN [Req1]. ON ([ Dept2].Cust2=[Req1].Cust) ON
Products2.StockNu=[Req1].StockNu2) WHERE
(([Req1].ReqFilledDate)<=forms![Report Date Range]!BeginDate) And
([Req1].ReqFilledDate<=forms![Report Date Range]!EndDate) GROUP BY
Products2.StockNu, Products2.ProductName, Dept2.Cust2, Dept2.Name;
Unfortunatly this does not work. My tables are:
Products2, holds all product info
Req1, holds requisition info from departments
Dept2, Info for all departments
that shows each departments totals for products ordered and what their monthy
charge is. This report must be divided by each department. Currently it says
there is a problem in the "FROM" line but has also said there is problems in
the "INNER JOIN" areas. My Database properties for this form is as follows.
The report is accessed by a date peramiter box;
SELECT DISTINCTROW Products2.StockNu, Products2.ProductName, Dept2.Cust2,
Dept2.DeptName, [Products2].AvgUnitPrice AS [Avg Unit Price],
Sum([Req1].QuantityIssued) AS [Total Units] FROM Products2 INNER JOIN (Dept2
INNER JOIN [Req1]. ON ([ Dept2].Cust2=[Req1].Cust) ON
Products2.StockNu=[Req1].StockNu2) WHERE
(([Req1].ReqFilledDate)<=forms![Report Date Range]!BeginDate) And
([Req1].ReqFilledDate<=forms![Report Date Range]!EndDate) GROUP BY
Products2.StockNu, Products2.ProductName, Dept2.Cust2, Dept2.Name;
Unfortunatly this does not work. My tables are:
Products2, holds all product info
Req1, holds requisition info from departments
Dept2, Info for all departments