Running sum question again 
Author Message
 Running sum question again

I asked this last week and didn't get a reply so I'm gonna try once
more.

I have a quote main form with a field called PriceSubTotal.
There is a subform called PartSummary and it has a field called
ExtendedPrice.  This subform can contain many Parts for that one quote
in the main form.

After updating something in the subform, I want the PriceSubTotal to
equal the sums of all the extendedprice of the parts for that one quote.

I tried doing a =Sum(extendedprice) in the footer of the subform and
having the PriceSubTotal equal that.  It didnt work.

Thanks.

Ngan



Sun, 01 Sep 2002 03:00:00 GMT  
 Running sum question again
I have had a problem like this, and the trouble was that in the subform
there was calculated fields directly in the subforms. Once we change the
query source of de subform to generate the calculated fields instead of do
the operation in the subform, the sum function in the footer works allright.

Ngan Bui escribi:

Quote:
> I asked this last week and didn't get a reply so I'm gonna try once
> more.

> I have a quote main form with a field called PriceSubTotal.
> There is a subform called PartSummary and it has a field called
> ExtendedPrice.  This subform can contain many Parts for that one quote
> in the main form.

> After updating something in the subform, I want the PriceSubTotal to
> equal the sums of all the extendedprice of the parts for that one quote.

> I tried doing a =Sum(extendedprice) in the footer of the subform and
> having the PriceSubTotal equal that.  It didnt work.

> Thanks.

> Ngan

--
___ Antonio Gadea Boronat __________________________________________________

|   Universidad de Alicante
|   Servicio de Informtica - Operacin



Sun, 01 Sep 2002 03:00:00 GMT  
 Running sum question again

Quote:

> I have had a problem like this, and the trouble was that in the subform
> there was calculated fields directly in the subforms. Once we change the
> query source of de subform to generate the calculated fields instead of do
> the operation in the subform, the sum function in the footer works allright.

hmm...i did put the sum function in the query...but it only summed up the price
for each record.  i had to do a DSum...I was hoping there was something I could
do that didn't involve DSum.

Thanks.

Ngan



Sun, 01 Sep 2002 03:00:00 GMT  
 Running sum question again
If you prefer not to use a DSum.  You might like to consider a design change
to your subform.  Set its form porperty Default View to continuous.  Then
put the calculating field in the subform footer (not in the main form).
This will only sum records showing in the subform due to link Child/Main
field criteria.  If you like you can set this field's Visible property to
False.  Then have the main form = this calculating field.

Luck
Jonathan


Quote:


> > I have had a problem like this, and the trouble was that in the subform
> > there was calculated fields directly in the subforms. Once we change the
> > query source of de subform to generate the calculated fields instead of
do
> > the operation in the subform, the sum function in the footer works
allright.

> hmm...i did put the sum function in the query...but it only summed up the
price
> for each record.  i had to do a DSum...I was hoping there was something I
could
> do that didn't involve DSum.

> Thanks.

> Ngan



Fri, 06 Sep 2002 03:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. How to do a Running Sum with Only Negatives

2. Running sums on a FORM??

3. Running sum

4. Running Sums in Forms

5. How to Count with Running Sum

6. Running Sums with queries

7. AM I missing something - Sum and Cumulative Sum

8. Running Sum

9. Creating a running sum query

10. running sum

11. Help!, running sum on form!

12. Article: How to create a running sum on a form

 

 
Powered by phpBB® Forum Software