I thought it might be easier to provide you a copy of my DB so you can see what I have going on. I'm a noobie so I'm sure that things are not as optimized as they could be.
When you open the DB the main form will open up. On the left side is where the operator enters in their records. The...
Would your formula give an actual number or an average? Just asking because of the "DCount" keyword. I already have it doing averages on my chart but want an actual number.
The code I'm using for averages is:
SELECT [Part Number],Avg(([Waste%])) AS [-Waste%] FROM...
I think part of the problem is that the field for "Part Number resides in a different table called "tblProductList" and not in the table for tblProductionNumbers.
I tried the code below (and several other iterations) to allow for the different table.
Actual Waste%: DSum(" [LF Run]-[LF...
This is the whole code in the query:
Actual Waste%: DSum(" [LF Run]-[LF Produced]","tblProductionNumbers","Part Number='HOC'")/DCount("*","tblProductionNumbers","Part Number='HOC'")
I still get the error and when I acknowldege it I get a dialog box that says "unknown"
I modified this code a little bit. A product they are running right now is called "HOC" instead of "LL100". Instead of "Product" as the table field it is actually "Part Number" (sorry).
I am getting an error of "Syntax error (missing operator) in query expression 'Part Number=HOC'.
Thank you for the reply PWise.
How would you code this so that the "LL100" could be any product? We produce about 20 products and the query could be any of those, just depends on what they are producing that day.
I am trying to create a DSum formula (to use as a control source in a chart) in a query that will look at a particular set of records(based on a product type), and take the value of that record's waste number (a calculated number) and divide that by the value of that record's LF Run number...
I have salesmen throughout the country. Each salesman sells in a particular state. I want to total up each salesman's invoice sales for the prior month (I will also do this for: July 2010, %Difference between July 2011/July2010, YTD 2010, YTD2011, and percent difference between YTD2010 and...
I am using CR2008
I am creating a report for our salesmen and one of the fields in the report will be a text box that shows what the last month was. For instance, if the report is run this month, the report will plug July 2011 into the box because that was what last month was. Tied to this will...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.