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 » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Count a subset of records in a query



 
 
Thread Tools Display Modes
  #1  
Old October 4th, 2006, 09:41 PM posted to microsoft.public.access.forms
Dblosevn
external usenet poster
 
Posts: 5
Default Count a subset of records in a query

I am trying to place a footer on a form which counts a subset of the records
that the form displays based on one of its fields. The form uses a query to
display its data which is extracted from company mainframe and updated
nightly. The query and forms break down the data by day and workgroup. I want
to be able to display the number of records counted by one of its fields
which is a drop down list and restricts user to a limited number of
selections.
  #2  
Old October 4th, 2006, 09:56 PM posted to microsoft.public.access.forms
Wayne-I-M
external usenet poster
 
Posts: 3,674
Default Count a subset of records in a query

Not really sure if I understand what you are looking for but I "think" you
are looking to count the number of times a specific string appears in a field
in the query that the form is based on ???

Use this is the source of an unbound text box in the form footer
=DCount("*", "[QueryName]", "[FieldName] = 'Something'")

Let me know if this is what you need as there are other methods

--
Wayne
Manchester, England.
Enjoy whatever it is you do


"Dblosevn" wrote:

I am trying to place a footer on a form which counts a subset of the records
that the form displays based on one of its fields. The form uses a query to
display its data which is extracted from company mainframe and updated
nightly. The query and forms break down the data by day and workgroup. I want
to be able to display the number of records counted by one of its fields
which is a drop down list and restricts user to a limited number of
selections.

  #3  
Old October 4th, 2006, 10:29 PM posted to microsoft.public.access.forms
Dblosevn
external usenet poster
 
Posts: 5
Default Count a subset of records in a query

I am getting an #Error message

I copied and pasted the text and changed the particulars to this:

=DCount("*","[qryStartsTbl]","[Contact Feedback] = 'Not Called'")



"Wayne-I-M" wrote:

Not really sure if I understand what you are looking for but I "think" you
are looking to count the number of times a specific string appears in a field
in the query that the form is based on ???

Use this is the source of an unbound text box in the form footer
=DCount("*", "[QueryName]", "[FieldName] = 'Something'")

Let me know if this is what you need as there are other methods

--
Wayne
Manchester, England.
Enjoy whatever it is you do


"Dblosevn" wrote:

I am trying to place a footer on a form which counts a subset of the records
that the form displays based on one of its fields. The form uses a query to
display its data which is extracted from company mainframe and updated
nightly. The query and forms break down the data by day and workgroup. I want
to be able to display the number of records counted by one of its fields
which is a drop down list and restricts user to a limited number of
selections.

  #4  
Old October 4th, 2006, 10:51 PM posted to microsoft.public.access.forms
David F Cox
external usenet poster
 
Posts: 493
Default Count a subset of records in a query

I have never used DCOUNT but Help says that the first argument should be a
field name.


"Dblosevn" wrote in message
...
I am getting an #Error message

I copied and pasted the text and changed the particulars to this:

=DCount("*","[qryStartsTbl]","[Contact Feedback] = 'Not Called'")



"Wayne-I-M" wrote:

Not really sure if I understand what you are looking for but I "think"
you
are looking to count the number of times a specific string appears in a
field
in the query that the form is based on ???

Use this is the source of an unbound text box in the form footer
=DCount("*", "[QueryName]", "[FieldName] = 'Something'")

Let me know if this is what you need as there are other methods

--
Wayne
Manchester, England.
Enjoy whatever it is you do


"Dblosevn" wrote:

I am trying to place a footer on a form which counts a subset of the
records
that the form displays based on one of its fields. The form uses a
query to
display its data which is extracted from company mainframe and updated
nightly. The query and forms break down the data by day and workgroup.
I want
to be able to display the number of records counted by one of its
fields
which is a drop down list and restricts user to a limited number of
selections.




  #5  
Old October 4th, 2006, 11:28 PM posted to microsoft.public.access.forms
Dblosevn
external usenet poster
 
Posts: 5
Default Count a subset of records in a query

Microsoft should realize that their "Help" is not very helpful at all and
most of the help I have gotten is either somewhere else or I figure it out on
my own. The help in MS says in one example the Field name first and another
slightly different example the table name first.

"David F Cox" wrote:

I have never used DCOUNT but Help says that the first argument should be a
field name.


"Dblosevn" wrote in message
...
I am getting an #Error message

I copied and pasted the text and changed the particulars to this:

=DCount("*","[qryStartsTbl]","[Contact Feedback] = 'Not Called'")



"Wayne-I-M" wrote:

Not really sure if I understand what you are looking for but I "think"
you
are looking to count the number of times a specific string appears in a
field
in the query that the form is based on ???

Use this is the source of an unbound text box in the form footer
=DCount("*", "[QueryName]", "[FieldName] = 'Something'")

Let me know if this is what you need as there are other methods

--
Wayne
Manchester, England.
Enjoy whatever it is you do


"Dblosevn" wrote:

I am trying to place a footer on a form which counts a subset of the
records
that the form displays based on one of its fields. The form uses a
query to
display its data which is extracted from company mainframe and updated
nightly. The query and forms break down the data by day and workgroup.
I want
to be able to display the number of records counted by one of its
fields
which is a drop down list and restricts user to a limited number of
selections.





  #6  
Old October 4th, 2006, 11:31 PM posted to microsoft.public.access.forms
Wayne-I-M
external usenet poster
 
Posts: 3,674
Default Count a subset of records in a query

Sorry my fault - I assumed you have created the lookup.

To Start
Creat 1 field and 1 lable (call the lable Stuff) in your footer (you don't
have to but it's a great cheat for variables)

In the lable insert the word Not Called
In the Text Box use this as the data
=DCount("IDField","qryStartsTbl","Contact Feedback"=[Stuff])

The ID field is the primary field of the records in your query so change
this to whatever you use (the name of the field)

I KNOW it's not how your meant to use DCount But

Hope this helps
--
Wayne
Manchester, England.
Enjoy whatever it is you do


"David F Cox" wrote:

I have never used DCOUNT but Help says that the first argument should be a
field name.


"Dblosevn" wrote in message
...
I am getting an #Error message

I copied and pasted the text and changed the particulars to this:

=DCount("*","[qryStartsTbl]","[Contact Feedback] = 'Not Called'")



"Wayne-I-M" wrote:

Not really sure if I understand what you are looking for but I "think"
you
are looking to count the number of times a specific string appears in a
field
in the query that the form is based on ???

Use this is the source of an unbound text box in the form footer
=DCount("*", "[QueryName]", "[FieldName] = 'Something'")

Let me know if this is what you need as there are other methods

--
Wayne
Manchester, England.
Enjoy whatever it is you do


"Dblosevn" wrote:

I am trying to place a footer on a form which counts a subset of the
records
that the form displays based on one of its fields. The form uses a
query to
display its data which is extracted from company mainframe and updated
nightly. The query and forms break down the data by day and workgroup.
I want
to be able to display the number of records counted by one of its
fields
which is a drop down list and restricts user to a limited number of
selections.





  #7  
Old October 4th, 2006, 11:38 PM posted to microsoft.public.access.forms
Wayne-I-M
external usenet poster
 
Posts: 3,674
Default Count a subset of records in a query

Hope you have that sorted.

I have placed an unbound combo on a form I made for a firm a while back and
in the combo there were a number of criteria that managements wanted to check
on
Off Sick
At Work
Went home early
Etc

(I know big brother is watching you ...)

Anyway assuming that you have the D Count function sorted all you need to do
is select from the combo (it's not called Stuff but it would work) you can
then D Count any crteira very quickly.

Just a thought... you may want to bring into your form one day.

Good luck with your project

--
Wayne
Manchester, England.
Enjoy whatever it is you do


"Wayne-I-M" wrote:

Sorry my fault - I assumed you have created the lookup.

To Start
Creat 1 field and 1 lable (call the lable Stuff) in your footer (you don't
have to but it's a great cheat for variables)

In the lable insert the word Not Called
In the Text Box use this as the data
=DCount("IDField","qryStartsTbl","Contact Feedback"=[Stuff])

The ID field is the primary field of the records in your query so change
this to whatever you use (the name of the field)

I KNOW it's not how your meant to use DCount But

Hope this helps
--
Wayne
Manchester, England.
Enjoy whatever it is you do


"David F Cox" wrote:

I have never used DCOUNT but Help says that the first argument should be a
field name.


"Dblosevn" wrote in message
...
I am getting an #Error message

I copied and pasted the text and changed the particulars to this:

=DCount("*","[qryStartsTbl]","[Contact Feedback] = 'Not Called'")



"Wayne-I-M" wrote:

Not really sure if I understand what you are looking for but I "think"
you
are looking to count the number of times a specific string appears in a
field
in the query that the form is based on ???

Use this is the source of an unbound text box in the form footer
=DCount("*", "[QueryName]", "[FieldName] = 'Something'")

Let me know if this is what you need as there are other methods

--
Wayne
Manchester, England.
Enjoy whatever it is you do


"Dblosevn" wrote:

I am trying to place a footer on a form which counts a subset of the
records
that the form displays based on one of its fields. The form uses a
query to
display its data which is extracted from company mainframe and updated
nightly. The query and forms break down the data by day and workgroup.
I want
to be able to display the number of records counted by one of its
fields
which is a drop down list and restricts user to a limited number of
selections.




  #8  
Old October 5th, 2006, 11:35 PM posted to microsoft.public.access.forms
Dblosevn
external usenet poster
 
Posts: 5
Default Count a subset of records in a query

OK, you said to call the label "Stuff" then you said "Not Called". Which is it?

"Wayne-I-M" wrote:

Sorry my fault - I assumed you have created the lookup.

To Start
Creat 1 field and 1 lable (call the lable Stuff) in your footer (you don't
have to but it's a great cheat for variables)

In the lable insert the word Not Called
In the Text Box use this as the data
=DCount("IDField","qryStartsTbl","Contact Feedback"=[Stuff])

The ID field is the primary field of the records in your query so change
this to whatever you use (the name of the field)

I KNOW it's not how your meant to use DCount But

Hope this helps
--
Wayne
Manchester, England.
Enjoy whatever it is you do


"David F Cox" wrote:

I have never used DCOUNT but Help says that the first argument should be a
field name.


"Dblosevn" wrote in message
...
I am getting an #Error message

I copied and pasted the text and changed the particulars to this:

=DCount("*","[qryStartsTbl]","[Contact Feedback] = 'Not Called'")



"Wayne-I-M" wrote:

Not really sure if I understand what you are looking for but I "think"
you
are looking to count the number of times a specific string appears in a
field
in the query that the form is based on ???

Use this is the source of an unbound text box in the form footer
=DCount("*", "[QueryName]", "[FieldName] = 'Something'")

Let me know if this is what you need as there are other methods

--
Wayne
Manchester, England.
Enjoy whatever it is you do


"Dblosevn" wrote:

I am trying to place a footer on a form which counts a subset of the
records
that the form displays based on one of its fields. The form uses a
query to
display its data which is extracted from company mainframe and updated
nightly. The query and forms break down the data by day and workgroup.
I want
to be able to display the number of records counted by one of its
fields
which is a drop down list and restricts user to a limited number of
selections.




 




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 05:49 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.