Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Subtract Quantity sold from inventory

Status
Not open for further replies.

TGrahmann

Programmer
Feb 19, 2015
43
US
So, I'm writing a POS, and I've Constructed the Actual POS form to insert SKUs added to go into a table called "Temppos". In Temppos goes, "SKU", "LONGDESC" (long description), "QUANTITY", "PRICE". How would I subtract the "QUANTITY" value from TEMPPOS from the value in INVENTORY (the Inventory Table), considering that there are multiple SKUs?
 
I was about to make a similar point myself. You can do a progress report within a loop, but not during a single command, so your WAIT WINDOW won't work if you are using UPDATE. But note what Olaf said about TALK and ODOMOETER.

Also, if you have a particularly large table, consider showing the progress after every, say, 100 records, rather than after every record. The point is that the act of displaying the progress (by whatever method) itself takes time, and if you do it too often, it could slow down the whole process.

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro articles, tips and downloads
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top