jazminecat
Programmer
Hi - I have a table with many fields, and I am working with fields ProdScrapRate and ProdYield. I imported the data for Yield from an excel spreadsheet.
Both ProdScrapRate and ProdYield are percentages.
The data field size is decimal,
format=percent,
scale and decimal places set to 2.
Scraprate is currently zeroes.
I need to run an update query to calculate the Prodscraprate - it's just 100 - Prodyield,
so if the yield is 98% the scraprate is 2%.
The ProdYield will eventually be a deleted field, I just need to do this calculation and then I can delete it.
However, I can't get an update query to produce any results. The sql currently reads:
UPDATE tblProducts SET tblProducts.ProdScrapRate = [ProdYield]-100;
this just gives me zero percentages in my ProdScrapRate field.
I just built it in the design window, I didn't write the SQL.
I have also tried it as
UPDATE tblProducts SET tblProducts.ProdScrapRate = 100-[ProdYield];
which also gives me zeros.
Thanks in advance for your advice!
Both ProdScrapRate and ProdYield are percentages.
The data field size is decimal,
format=percent,
scale and decimal places set to 2.
Scraprate is currently zeroes.
I need to run an update query to calculate the Prodscraprate - it's just 100 - Prodyield,
so if the yield is 98% the scraprate is 2%.
The ProdYield will eventually be a deleted field, I just need to do this calculation and then I can delete it.
However, I can't get an update query to produce any results. The sql currently reads:
UPDATE tblProducts SET tblProducts.ProdScrapRate = [ProdYield]-100;
this just gives me zero percentages in my ProdScrapRate field.
I just built it in the design window, I didn't write the SQL.
I have also tried it as
UPDATE tblProducts SET tblProducts.ProdScrapRate = 100-[ProdYield];
which also gives me zeros.
Thanks in advance for your advice!