summing costs from multiple records...

B

Brad Pears

I have a field that I want to display on a form. This field would be the sum
of all "cost" fields from another table...

The SQL would be something like this...

select sum(cost) from [tasks].[cost] where [tasks].[issue_no] = me.issueno

How do I set up a calculated field to do this? SHould I not be able to place
this SQL code in the fields "Control Source" property? I tried that and the
field simply shows "Error"

Any help would be appreciated...

Brad
 
T

Treebeard

You can't define a fields control source by an sql query.

You have to use the function : DSum

Jack
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top