Combo Box Row Source

  • Thread starter Thread starter Jennifer
  • Start date Start date
J

Jennifer

I need to enter this informaion into a Row Source:

Select T.classname from classtable join qSumClasses Q on
t.classid = q.classid

It was the answer I got for a question I asked last month.
I have been entering it as:

SELECT [Classes].[Classes] FROM [Classes] JOIN [Class
Count] on [Classes]=[Class]

I have been getting an error.
I just need to know if I am entering the information wrong?

Please refer to the past message:

Subject: counting in forms
From: "Jennifer" <[email protected]>
Sent: 7/23/2003 2:09:01 PM

Thank you,
Jennifer
 
You don't say what the error is? Can you provide more info? Your previous
post is already deleted from my OE newsgroup folder, so I don't have it
available.
 
It is giving me an error that says:
Syntax error in FROM clause.

Thank you very much for your help.

Here are the previous messages:

Subject: Re: counting in forms
From: "HSalim" <[email protected]> Sent: 7/23/2003 6:28:23
PM


sorry, change that to a Count
HSalim said:
I suppose you are using the GUI
so you add classid
click on the sum (sigma) button, Group by appears in the totals row
now class id again, , make that a where
and then in the criteria type in < 10 under the where

Jennifer said:
HS,

Thank you for your help. I think this will work for me.
I just have one more quick question. Where in the query
do I type count(*) < 10 ?

Thank you again,

Jennifer

are
open. having
count(*) < 10 on
t.classid = drop
down box. only
want


..


-----Original Message-----
I need to enter this informaion into a Row Source:

Select T.classname from classtable join qSumClasses Q on
t.classid = q.classid

It was the answer I got for a question I asked last month.
I have been entering it as:

SELECT [Classes].[Classes] FROM [Classes] JOIN [Class
Count] on [Classes]=[Class]

I have been getting an error.
I just need to know if I am entering the information wrong?

Please refer to the past message:

Subject: counting in forms
From: "Jennifer" <[email protected]>
Sent: 7/23/2003 2:09:01 PM

Thank you,
Jennifer

.
 
Try this:

SELECT [Classes].[Classes] FROM [Classes]
INNER JOIN [Class Count] ON
[Classes].[Classes]=[Class Count].[Class];


--
Ken Snell
<MS ACCESS MVP>

Jennifer said:
It is giving me an error that says:
Syntax error in FROM clause.

Thank you very much for your help.

Here are the previous messages:

Subject: Re: counting in forms
From: "HSalim" <[email protected]> Sent: 7/23/2003 6:28:23
PM


sorry, change that to a Count
HSalim said:
I suppose you are using the GUI
so you add classid
click on the sum (sigma) button, Group by appears in the totals row
now class id again, , make that a where
and then in the criteria type in < 10 under the where

Jennifer said:
HS,

Thank you for your help. I think this will work for me.
I just have one more quick question. Where in the query
do I type count(*) < 10 ?

Thank you again,

Jennifer


-----Original Message-----
Jennifer,
there are a number of ways to do this.


Since you already have a form:
One way to do it is to only present the classes that are
open.
Your Combobox has a row source something like this
Select Classname from ClassTable

Instead try this:
1. create a query called qSumClasses
Select classid from studentclass group by classid having
count(*) < 10

2. Change the rowsource of your combobox to:
Select T.classname from classtable join qSumClasses Q on
t.classid =
q.classid

This will limit the classes you can select from the drop
down box.

There are of course other ways to do this, and this
suggestion may not be
appropriate for you.
so the next time, please post detailed questions.

Regards
HS


I have a database full of children that are registering
for classes. I am entering the names and classes via
forms. The classes are entered by using a combo box,
where the control source is a separate table. I only
want
ten children per class. How can I make the form tell me
that a class is full? If possible, could I please get a
step by step explanation? I am new to Access.
Thank you very much!
Jennifer



.


.


-----Original Message-----
I need to enter this informaion into a Row Source:

Select T.classname from classtable join qSumClasses Q on
t.classid = q.classid

It was the answer I got for a question I asked last month.
I have been entering it as:

SELECT [Classes].[Classes] FROM [Classes] JOIN [Class
Count] on [Classes]=[Class]

I have been getting an error.
I just need to know if I am entering the information wrong?

Please refer to the past message:

Subject: counting in forms
From: "Jennifer" <[email protected]>
Sent: 7/23/2003 2:09:01 PM

Thank you,
Jennifer

.
 
After entering what you suggested into the Row Source,
when I try and use the ComboBox, a box pops up that says:

Enter Parameter Value
Class Count.Class
Ok or Cancel

There is a place to enter text as well. I just clicked
ok, and the drop down list in the ComboBox was empty and
only showed one blank line. In the past I've found that
this had something to do with the Column Count and Column
Widths fields in the ComboBox Properties. When I get this
message, they are set to 1 and 1" respectively.

Class Count is a Query connected to a Table called Event.
The Table Event is where all the information from the Form
is being sent. There is another Table called Classes that
only has one column listing the class names. There is no
ID column in the Table Classes. I made the Table Classes
for the ComboBox in question, it is the Row Source. The
only field in the Query Class Count is Class from the
Table Event and I put in the Total line Count and in the
Criteria line <10. The Query Class Count seems to work
just fine.

All I want to happen is for the Form to notify me, either
by eliminating a class from the list, or by some other
means, when a class has been filled with 10 children.

If there is a better way to do this, than what I'm trying,
please let me know.

Thank you,
Jennifer


-----Original Message-----
Try this:

SELECT [Classes].[Classes] FROM [Classes]
INNER JOIN [Class Count] ON
[Classes].[Classes]=[Class Count].[Class];


--
Ken Snell
<MS ACCESS MVP>

Jennifer said:
It is giving me an error that says:
Syntax error in FROM clause.

Thank you very much for your help.

Here are the previous messages:

Subject: Re: counting in forms
From: "HSalim" <[email protected]> Sent: 7/23/2003 6:28:23
PM


sorry, change that to a Count
HSalim said:
I suppose you are using the GUI
so you add classid
click on the sum (sigma) button, Group by appears in the totals row
now class id again, , make that a where
and then in the criteria type in < 10 under the where

HS,

Thank you for your help. I think this will work for me.
I just have one more quick question. Where in the query
do I type count(*) < 10 ?

Thank you again,

Jennifer


-----Original Message-----
Jennifer,
there are a number of ways to do this.


Since you already have a form:
One way to do it is to only present the classes
that
are
open.
Your Combobox has a row source something like this
Select Classname from ClassTable

Instead try this:
1. create a query called qSumClasses
Select classid from studentclass group by classid having
count(*) < 10

2. Change the rowsource of your combobox to:
Select T.classname from classtable join
qSumClasses Q
on
t.classid =
q.classid

This will limit the classes you can select from the drop
down box.

There are of course other ways to do this, and this
suggestion may not be
appropriate for you.
so the next time, please post detailed questions.

Regards
HS


I have a database full of children that are registering
for classes. I am entering the names and classes via
forms. The classes are entered by using a combo box,
where the control source is a separate table. I only
want
ten children per class. How can I make the form tell me
that a class is full? If possible, could I
please
get a
step by step explanation? I am new to Access.
Thank you very much!
Jennifer



.




.


-----Original Message-----
I need to enter this informaion into a Row Source:

Select T.classname from classtable join qSumClasses Q on
t.classid = q.classid

It was the answer I got for a question I asked last month.
I have been entering it as:

SELECT [Classes].[Classes] FROM [Classes] JOIN [Class
Count] on [Classes]=[Class]

I have been getting an error.
I just need to know if I am entering the information wrong?

Please refer to the past message:

Subject: counting in forms
From: "Jennifer" <[email protected]>
Sent: 7/23/2003 2:09:01 PM

Thank you,
Jennifer

.


.
 
Let me back up.

You have a table named Classes that has one field (named Classes?); this
field contains the names of the different classes.

You have a table named Event that is receiving the data from your form.

You have a query named Class Count, which apparently is a totals query. This
query contains two fields: Class (from the Event table), and Total line
Count (which apparently is the number of "students" in the Class). The
criterion on Total line Count is <10.

Thus, your desire is to display in your combo box's dropdown list only the
classes from the field in the Classes table that currently have less than 10
students.

Am I on track so far?

May I assume that the Classes field in the Classes table contains the same
class names as the Class field in the Class Count query (and as the Class
field in the Event table)?

Assuming that this is all correct, then what you want is to "filter out"
from the list of Classes in the Classes table all the classes where 10
students (or more) are already assigned. The query SQL that you've been
trying to use will not show classes from the Classes table that are not
already in the Event table; I assume that that is not a correct result.

Change the criterion expression for the Total line Count field in the Class
Count query to this:

Then try this SQL as the Row Source for your combo box:

SELECT Classes.Classes FROM Classes
WHERE Classes.Classes NOT IN
(SELECT Class FROM [Class Count]);


--
Ken Snell
<MS ACCESS MVP>

Jennifer said:
After entering what you suggested into the Row Source,
when I try and use the ComboBox, a box pops up that says:

Enter Parameter Value
Class Count.Class
Ok or Cancel

There is a place to enter text as well. I just clicked
ok, and the drop down list in the ComboBox was empty and
only showed one blank line. In the past I've found that
this had something to do with the Column Count and Column
Widths fields in the ComboBox Properties. When I get this
message, they are set to 1 and 1" respectively.

Class Count is a Query connected to a Table called Event.
The Table Event is where all the information from the Form
is being sent. There is another Table called Classes that
only has one column listing the class names. There is no
ID column in the Table Classes. I made the Table Classes
for the ComboBox in question, it is the Row Source. The
only field in the Query Class Count is Class from the
Table Event and I put in the Total line Count and in the
Criteria line <10. The Query Class Count seems to work
just fine.

All I want to happen is for the Form to notify me, either
by eliminating a class from the list, or by some other
means, when a class has been filled with 10 children.

If there is a better way to do this, than what I'm trying,
please let me know.

Thank you,
Jennifer


-----Original Message-----
Try this:

SELECT [Classes].[Classes] FROM [Classes]
INNER JOIN [Class Count] ON
[Classes].[Classes]=[Class Count].[Class];


--
Ken Snell
<MS ACCESS MVP>

Jennifer said:
It is giving me an error that says:
Syntax error in FROM clause.

Thank you very much for your help.

Here are the previous messages:

Subject: Re: counting in forms
From: "HSalim" <[email protected]> Sent: 7/23/2003 6:28:23
PM


sorry, change that to a Count
I suppose you are using the GUI
so you add classid
click on the sum (sigma) button, Group by appears in
the totals row
now class id again, , make that a where
and then in the criteria type in < 10 under the where

HS,

Thank you for your help. I think this will work for
me.
I just have one more quick question. Where in the
query
do I type count(*) < 10 ?

Thank you again,

Jennifer


-----Original Message-----
Jennifer,
there are a number of ways to do this.


Since you already have a form:
One way to do it is to only present the classes that
are
open.
Your Combobox has a row source something like this
Select Classname from ClassTable

Instead try this:
1. create a query called qSumClasses
Select classid from studentclass group by classid
having
count(*) < 10

2. Change the rowsource of your combobox to:
Select T.classname from classtable join qSumClasses Q
on
t.classid =
q.classid

This will limit the classes you can select from the
drop
down box.

There are of course other ways to do this, and this
suggestion may not be
appropriate for you.
so the next time, please post detailed questions.

Regards
HS


I have a database full of children that are
registering
for classes. I am entering the names and classes
via
forms. The classes are entered by using a combo
box,
where the control source is a separate table. I
only
want
ten children per class. How can I make the form
tell me
that a class is full? If possible, could I please
get a
step by step explanation? I am new to Access.
Thank you very much!
Jennifer



.





.


-----Original Message-----
I need to enter this informaion into a Row Source:

Select T.classname from classtable join qSumClasses Q on
t.classid = q.classid

It was the answer I got for a question I asked last month.
I have been entering it as:

SELECT [Classes].[Classes] FROM [Classes] JOIN [Class
Count] on [Classes]=[Class]

I have been getting an error.
I just need to know if I am entering the information
wrong?

Please refer to the past message:

Subject: counting in forms
From: "Jennifer" <[email protected]>
Sent: 7/23/2003 2:09:01 PM

Thank you,
Jennifer

.


.
 
You're welcome.

Jennifer said:
Thank you very much!
You were correct and it worked the way I wanted it to.
Thank you again,
Jennifer
-----Original Message-----
Let me back up.

You have a table named Classes that has one field (named Classes?); this
field contains the names of the different classes.

You have a table named Event that is receiving the data from your form.

You have a query named Class Count, which apparently is a totals query. This
query contains two fields: Class (from the Event table), and Total line
Count (which apparently is the number of "students" in the Class). The
criterion on Total line Count is <10.

Thus, your desire is to display in your combo box's dropdown list only the
classes from the field in the Classes table that currently have less than 10
students.

Am I on track so far?

May I assume that the Classes field in the Classes table contains the same
class names as the Class field in the Class Count query (and as the Class
field in the Event table)?

Assuming that this is all correct, then what you want is to "filter out"
from the list of Classes in the Classes table all the classes where 10
students (or more) are already assigned. The query SQL that you've been
trying to use will not show classes from the Classes table that are not
already in the Event table; I assume that that is not a correct result.

Change the criterion expression for the Total line Count field in the Class
Count query to this:

Then try this SQL as the Row Source for your combo box:

SELECT Classes.Classes FROM Classes
WHERE Classes.Classes NOT IN
(SELECT Class FROM [Class Count]);


--
Ken Snell
<MS ACCESS MVP>

Jennifer said:
After entering what you suggested into the Row Source,
when I try and use the ComboBox, a box pops up that says:

Enter Parameter Value
Class Count.Class
Ok or Cancel

There is a place to enter text as well. I just clicked
ok, and the drop down list in the ComboBox was empty and
only showed one blank line. In the past I've found that
this had something to do with the Column Count and Column
Widths fields in the ComboBox Properties. When I get this
message, they are set to 1 and 1" respectively.

Class Count is a Query connected to a Table called Event.
The Table Event is where all the information from the Form
is being sent. There is another Table called Classes that
only has one column listing the class names. There is no
ID column in the Table Classes. I made the Table Classes
for the ComboBox in question, it is the Row Source. The
only field in the Query Class Count is Class from the
Table Event and I put in the Total line Count and in the
Criteria line <10. The Query Class Count seems to work
just fine.

All I want to happen is for the Form to notify me, either
by eliminating a class from the list, or by some other
means, when a class has been filled with 10 children.

If there is a better way to do this, than what I'm trying,
please let me know.

Thank you,
Jennifer



-----Original Message-----
Try this:

SELECT [Classes].[Classes] FROM [Classes]
INNER JOIN [Class Count] ON
[Classes].[Classes]=[Class Count].[Class];


--
Ken Snell
<MS ACCESS MVP>

It is giving me an error that says:
Syntax error in FROM clause.

Thank you very much for your help.

Here are the previous messages:

Subject: Re: counting in forms
From: "HSalim" <[email protected]> Sent: 7/23/2003
6:28:23
PM


sorry, change that to a Count
I suppose you are using the GUI
so you add classid
click on the sum (sigma) button, Group by appears in
the totals row
now class id again, , make that a where
and then in the criteria type in < 10 under the where

HS,

Thank you for your help. I think this will work for
me.
I just have one more quick question. Where in the
query
do I type count(*) < 10 ?

Thank you again,

Jennifer


-----Original Message-----
Jennifer,
there are a number of ways to do this.


Since you already have a form:
One way to do it is to only present the classes
that
are
open.
Your Combobox has a row source something like this
Select Classname from ClassTable

Instead try this:
1. create a query called qSumClasses
Select classid from studentclass group by classid
having
count(*) < 10

2. Change the rowsource of your combobox to:
Select T.classname from classtable join
qSumClasses Q
on
t.classid =
q.classid

This will limit the classes you can select from the
drop
down box.

There are of course other ways to do this, and this
suggestion may not be
appropriate for you.
so the next time, please post detailed questions.

Regards
HS


I have a database full of children that are
registering
for classes. I am entering the names and classes
via
forms. The classes are entered by using a combo
box,
where the control source is a separate table. I
only
want
ten children per class. How can I make the form
tell me
that a class is full? If possible, could I
please
get a
step by step explanation? I am new to Access.
Thank you very much!
Jennifer



.





.


-----Original Message-----
I need to enter this informaion into a Row Source:

Select T.classname from classtable join qSumClasses Q
on
t.classid = q.classid

It was the answer I got for a question I asked last
month.
I have been entering it as:

SELECT [Classes].[Classes] FROM [Classes] JOIN [Class
Count] on [Classes]=[Class]

I have been getting an error.
I just need to know if I am entering the information
wrong?

Please refer to the past message:

Subject: counting in forms
From: "Jennifer" <[email protected]>
Sent: 7/23/2003 2:09:01 PM

Thank you,
Jennifer

.



.


.
 
Back
Top