Need assistance with an expression

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I hope that someone can help me. I have a database with a dropdown listing
five different levels. The levels are numbered 0 - 4. Each level has a
corresponding point value. For example - 1=5 pts, 2=10 pts, etc. The points
are not contained in the database.

What I need to do is list the corresponding point value for the level and
then total the points at the end of the report (this I do know how to do).

Is there a simple way to do this within Access?

Thanks.
 
It might be easiest to create a new column in your query:
Pts: Choose([Level] + 1, 0, 5, 10, ...)
You can then total this in your report.

A more robust solution would involve a table with 5 records containing the
level and points.
 
I'm not sure I know exactly what you mean here. can you give me a more
detailed explanation? Thanx.

Duane Hookom said:
It might be easiest to create a new column in your query:
Pts: Choose([Level] + 1, 0, 5, 10, ...)
You can then total this in your report.

A more robust solution would involve a table with 5 records containing the
level and points.

--
Duane Hookom
MS Access MVP
--

MCK said:
I hope that someone can help me. I have a database with a dropdown listing
five different levels. The levels are numbered 0 - 4. Each level has a
corresponding point value. For example - 1=5 pts, 2=10 pts, etc. The
points
are not contained in the database.

What I need to do is list the corresponding point value for the level and
then total the points at the end of the report (this I do know how to do).

Is there a simple way to do this within Access?

Thanks.
 
Did you try add the new column in your query (report record source)? Did it
work or not?

Are you asking about the table with 5 records? Assume you have 72 levels. Do
you want to create a huge expression using multiple Choose() or Switch() or
IIF()? Do you want to maintain expressions or data?

--
Duane Hookom
MS Access MVP
--

MCK said:
I'm not sure I know exactly what you mean here. can you give me a more
detailed explanation? Thanx.

Duane Hookom said:
It might be easiest to create a new column in your query:
Pts: Choose([Level] + 1, 0, 5, 10, ...)
You can then total this in your report.

A more robust solution would involve a table with 5 records containing
the
level and points.

--
Duane Hookom
MS Access MVP
--

MCK said:
I hope that someone can help me. I have a database with a dropdown
listing
five different levels. The levels are numbered 0 - 4. Each level has
a
corresponding point value. For example - 1=5 pts, 2=10 pts, etc. The
points
are not contained in the database.

What I need to do is list the corresponding point value for the level
and
then total the points at the end of the report (this I do know how to
do).

Is there a simple way to do this within Access?

Thanks.
 
I would like to add the column to the query, but I'm not sure how to enter
the details.

My Access skills are on the rusty side, but getting better. Haven't used
the program in years and am now using it heavily in a new job.



Duane Hookom said:
Did you try add the new column in your query (report record source)? Did it
work or not?

Are you asking about the table with 5 records? Assume you have 72 levels. Do
you want to create a huge expression using multiple Choose() or Switch() or
IIF()? Do you want to maintain expressions or data?

--
Duane Hookom
MS Access MVP
--

MCK said:
I'm not sure I know exactly what you mean here. can you give me a more
detailed explanation? Thanx.

Duane Hookom said:
It might be easiest to create a new column in your query:
Pts: Choose([Level] + 1, 0, 5, 10, ...)
You can then total this in your report.

A more robust solution would involve a table with 5 records containing
the
level and points.

--
Duane Hookom
MS Access MVP
--

I hope that someone can help me. I have a database with a dropdown
listing
five different levels. The levels are numbered 0 - 4. Each level has
a
corresponding point value. For example - 1=5 pts, 2=10 pts, etc. The
points
are not contained in the database.

What I need to do is list the corresponding point value for the level
and
then total the points at the end of the report (this I do know how to
do).

Is there a simple way to do this within Access?

Thanks.
 
Open the report's record source query in design view. Find a new blank
column in the grid. In the top row, add
Pts: Choose([Level] + 1, 0, 5, 10, ...)
Where Level is the field that contains the values 0-4. The 0, 5, 10,.. are
for the values to return if the Level field is 0, 1, 2,.. You need to enter
the values for 3 and 4.

--
Duane Hookom
MS Access MVP
--

MCK said:
I would like to add the column to the query, but I'm not sure how to enter
the details.

My Access skills are on the rusty side, but getting better. Haven't used
the program in years and am now using it heavily in a new job.



Duane Hookom said:
Did you try add the new column in your query (report record source)? Did
it
work or not?

Are you asking about the table with 5 records? Assume you have 72 levels.
Do
you want to create a huge expression using multiple Choose() or Switch()
or
IIF()? Do you want to maintain expressions or data?

--
Duane Hookom
MS Access MVP
--

MCK said:
I'm not sure I know exactly what you mean here. can you give me a more
detailed explanation? Thanx.

:

It might be easiest to create a new column in your query:
Pts: Choose([Level] + 1, 0, 5, 10, ...)
You can then total this in your report.

A more robust solution would involve a table with 5 records containing
the
level and points.

--
Duane Hookom
MS Access MVP
--

I hope that someone can help me. I have a database with a dropdown
listing
five different levels. The levels are numbered 0 - 4. Each level
has
a
corresponding point value. For example - 1=5 pts, 2=10 pts, etc.
The
points
are not contained in the database.

What I need to do is list the corresponding point value for the
level
and
then total the points at the end of the report (this I do know how
to
do).

Is there a simple way to do this within Access?

Thanks.
 
I think I may have figured it out, then realized another problem, which I
will try to fix tomorrow. I added the new table, added it to the query and
ran my report. That's when I realized my other issue. The same scenario is
actually in two different areas of the database - the fields have different
names, because different people are responsible for assigning the levels, but
the point system is the same and they must be included in the report as well.
So do I need to add the other field to the table, or have a separate table?
I'm thinking a separate table...

MCK said:
I would like to add the column to the query, but I'm not sure how to enter
the details.

My Access skills are on the rusty side, but getting better. Haven't used
the program in years and am now using it heavily in a new job.



Duane Hookom said:
Did you try add the new column in your query (report record source)? Did it
work or not?

Are you asking about the table with 5 records? Assume you have 72 levels. Do
you want to create a huge expression using multiple Choose() or Switch() or
IIF()? Do you want to maintain expressions or data?

--
Duane Hookom
MS Access MVP
--

MCK said:
I'm not sure I know exactly what you mean here. can you give me a more
detailed explanation? Thanx.

:

It might be easiest to create a new column in your query:
Pts: Choose([Level] + 1, 0, 5, 10, ...)
You can then total this in your report.

A more robust solution would involve a table with 5 records containing
the
level and points.

--
Duane Hookom
MS Access MVP
--

I hope that someone can help me. I have a database with a dropdown
listing
five different levels. The levels are numbered 0 - 4. Each level has
a
corresponding point value. For example - 1=5 pts, 2=10 pts, etc. The
points
are not contained in the database.

What I need to do is list the corresponding point value for the level
and
then total the points at the end of the report (this I do know how to
do).

Is there a simple way to do this within Access?

Thanks.
 
You lost me. If the record values would be the same then one table should
work.

--
Duane Hookom
MS Access MVP
--

MCK said:
I think I may have figured it out, then realized another problem, which I
will try to fix tomorrow. I added the new table, added it to the query
and
ran my report. That's when I realized my other issue. The same scenario
is
actually in two different areas of the database - the fields have
different
names, because different people are responsible for assigning the levels,
but
the point system is the same and they must be included in the report as
well.
So do I need to add the other field to the table, or have a separate
table?
I'm thinking a separate table...

MCK said:
I would like to add the column to the query, but I'm not sure how to
enter
the details.

My Access skills are on the rusty side, but getting better. Haven't used
the program in years and am now using it heavily in a new job.



Duane Hookom said:
Did you try add the new column in your query (report record source)?
Did it
work or not?

Are you asking about the table with 5 records? Assume you have 72
levels. Do
you want to create a huge expression using multiple Choose() or
Switch() or
IIF()? Do you want to maintain expressions or data?

--
Duane Hookom
MS Access MVP
--

I'm not sure I know exactly what you mean here. can you give me a
more
detailed explanation? Thanx.

:

It might be easiest to create a new column in your query:
Pts: Choose([Level] + 1, 0, 5, 10, ...)
You can then total this in your report.

A more robust solution would involve a table with 5 records
containing
the
level and points.

--
Duane Hookom
MS Access MVP
--

I hope that someone can help me. I have a database with a dropdown
listing
five different levels. The levels are numbered 0 - 4. Each level
has
a
corresponding point value. For example - 1=5 pts, 2=10 pts, etc.
The
points
are not contained in the database.

What I need to do is list the corresponding point value for the
level
and
then total the points at the end of the report (this I do know how
to
do).

Is there a simple way to do this within Access?

Thanks.
 
The database was set up with the two fields - lets say for two different
committees. The values are the same, but the committees are different, so
two fields were added. I added the second table and the report seems to be
working fine.

Thanks for all of your help.

Duane Hookom said:
You lost me. If the record values would be the same then one table should
work.

--
Duane Hookom
MS Access MVP
--

MCK said:
I think I may have figured it out, then realized another problem, which I
will try to fix tomorrow. I added the new table, added it to the query
and
ran my report. That's when I realized my other issue. The same scenario
is
actually in two different areas of the database - the fields have
different
names, because different people are responsible for assigning the levels,
but
the point system is the same and they must be included in the report as
well.
So do I need to add the other field to the table, or have a separate
table?
I'm thinking a separate table...

MCK said:
I would like to add the column to the query, but I'm not sure how to
enter
the details.

My Access skills are on the rusty side, but getting better. Haven't used
the program in years and am now using it heavily in a new job.



:

Did you try add the new column in your query (report record source)?
Did it
work or not?

Are you asking about the table with 5 records? Assume you have 72
levels. Do
you want to create a huge expression using multiple Choose() or
Switch() or
IIF()? Do you want to maintain expressions or data?

--
Duane Hookom
MS Access MVP
--

I'm not sure I know exactly what you mean here. can you give me a
more
detailed explanation? Thanx.

:

It might be easiest to create a new column in your query:
Pts: Choose([Level] + 1, 0, 5, 10, ...)
You can then total this in your report.

A more robust solution would involve a table with 5 records
containing
the
level and points.

--
Duane Hookom
MS Access MVP
--

I hope that someone can help me. I have a database with a dropdown
listing
five different levels. The levels are numbered 0 - 4. Each level
has
a
corresponding point value. For example - 1=5 pts, 2=10 pts, etc.
The
points
are not contained in the database.

What I need to do is list the corresponding point value for the
level
and
then total the points at the end of the report (this I do know how
to
do).

Is there a simple way to do this within Access?

Thanks.
 
Back
Top