control to hold a single value in a report. (access 2002)

please see attached..
what will be the right control to place where the marked green box is.

the query in the 'REPORT' whose property is highlighted is as below (simplified, leaving out the complex conditions)
SELECT field1, Field2, Field3,Field4
FROM Book_Table
WHERE Condition1 AND condition2
ORDER BY Field2 DESC;

The new field to introduce below the above 'REPORT' control, would be of the below format:
SELECT avg(Field3)
FROM Book_Table
WHERE Condition1 AND condition2
heaader.png
LVL 5
25112Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

chaauCommented:
I think you are overdoing your report with sub-reports. In my opinion, even the ones you have marked red should not be sub-reports, bu just normal Text Boxes.

As for the avg(Field3) you can either use a simple Text Box. In the control source type Avg(Field3)
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
PatHartmanCommented:
what will be the right control to place where the marked green box is.
Usage of controls is not arbitrary.  What do you want to see in the control?  It looks to me like you probably want another subreport.
0
25112Author Commented:
>>What do you want to see in the control?
The new one will be an average.. so a single value.
the existing report (3 next to each other ) is a 3 column list..

if it is a single value, do you recommend subreport for any value/reason?
0
10 Tips to Protect Your Business from Ransomware

Did you know that ransomware is the most widespread, destructive malware in the world today? It accounts for 39% of all security breaches, with ransomware gangsters projected to make $11.5B in profits from online extortion by 2019.

PatHartmanCommented:
If it is a single value, then you can create an unbound text box and put the calculation in the ControlSource:

=DAvg("somefield", "sometableorquery", "somecriteriaifnecessary")
0
25112Author Commented:
the report source is a QUERY with
SELECT field1, Field2, Field3,Field4
 FROM Book_Table
 WHERE Condition1 AND condition2
 ORDER BY Field2 DESC;

for
SELECT avg(Field3)
 FROM Book_Table
 WHERE Condition1 AND condition2
in txt box, you mentioned: DAvg instead of avg. is that for specific reason?

so, will be it format like:
DAvg("Field3", "Book_Table", "Column1=1 AND Column2=2")
0
PatHartmanCommented:
Is that a question?
0
25112Author Commented:
thank you for confirming
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.