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. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
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
|
|||
|
|||
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
|
|||
|
|||
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
|
|||
|
|||
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
|
|||
|
|||
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
|
|||
|
|||
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
|
|||
|
|||
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
|
|||
|
|||
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 | |
|
|