A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Running & Setting Up Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

revers minus



 
 
Thread Tools Display Modes
  #1  
Old December 26th, 2009, 02:18 PM posted to microsoft.public.access.queries
mh_amri[_2_]
external usenet poster
 
Posts: 1
Default revers minus

hi guyz,we have little office and want to make some regular thing machinary
here it is:
we sell stuffs(for example think us as a newspaper company) , we give
newspaper to our seller and then they return the amount of newspaper that
remains at the end of the week , and because every day have a special rate
for income its important to calculate the sell amount from beginning
for example i give 150,100,250,400 newspaper to the seller and at the end of
the week he claim 300 of them has been sold, it means he sold out(*) 150 in
first day , and 100 in 2nd day and 50 in 3rd day9(**), and must return 200
for 3rd day and 400 for the 4th day
for this purpos i made a query that collect data about the day and the
amount that we gave the seller, and designed a form that take the amount of
that the seller sold out(this amount is a number for a whole week, for
example 300 ) , the problem is calculating the sold amount for each day(see
from * to **) , because each day have a rate value that it has read from
another table and multiply by the amount that sold on that day
i mean i want to do generate a table like this:
[seller] [day] [give amount] [sold amount] [retun amount]
1 1 150 150 0
1 2 100 100 0
1 3 250 50 200
1 4 400 0
400

my problem is calculating the the [sold amount] , the weekly returned amount
has entered in a form (here is 300) i have to give 300 to access and generate
the [sold amount]
i used many ways, but because the calculation of each row need to access the
last row data all of that way failed
anyway , any comment will appreciate


  #2  
Old December 26th, 2009, 08:08 PM posted to microsoft.public.access.queries
Bob Barrows
external usenet poster
 
Posts: 475
Default revers minus

mh_amri wrote:
hi guyz,we have little office and want to make some regular thing
machinary here it is:
we sell stuffs(for example think us as a newspaper company) , we give
newspaper to our seller and then they return the amount of newspaper
that remains at the end of the week , and because every day have a
special rate for income its important to calculate the sell amount
from beginning
for example i give 150,100,250,400 newspaper to the seller and at the
end of the week he claim 300 of them has been sold, it means he sold
out(*) 150 in first day , and 100 in 2nd day and 50 in 3rd day9(**),
and must return 200 for 3rd day and 400 for the 4th day
for this purpos i made a query that collect data about the day and the
amount that we gave the seller, and designed a form that take the
amount of that the seller sold out(this amount is a number for a
whole week, for example 300 ) , the problem is calculating the sold
amount for each day(see from * to **) , because each day have a rate
value that it has read from another table and multiply by the amount
that sold on that day
i mean i want to do generate a table like this:
[seller] [day] [give amount] [sold amount] [retun amount]
1 1 150 150
0 1 2 100 100
0 1 3 250 50
200 1 4 400 0
400

my problem is calculating the the [sold amount] , the weekly returned
amount has entered in a form (here is 300) i have to give 300 to
access and generate the [sold amount]
i used many ways, but because the calculation of each row need to
access the last row data all of that way failed
anyway , any comment will appreciate


Show us the structure (field names and data types) of the source data,
please. It's tough to tell you how to generate a result without knowing what
the data originally looks like.



--
Microsoft MVP - ASP/ASP.NET - 2004-2007
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 11:12 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.