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

How do I create a relationship to similar match in Access?



 
 
Thread Tools Display Modes
  #1  
Old November 19th, 2008, 12:07 AM posted to microsoft.public.access.tablesdbdesign
Joana Villas-Boas
external usenet poster
 
Posts: 6
Default How do I create a relationship to similar match in Access?

I have a table with minimum and maximum values to find out the ideal weight
for each heigth of the Client's Table.

I wan't to put the client hight and need access to Lookup on the other table
wich is the ideal weight for that person.

I am an expert in all sort of relationships, but don't know how to do this
one once it is not a direct relationship, it works more like the Lookup
function in excel.

Is this possible in Access?
  #2  
Old November 19th, 2008, 12:23 AM posted to microsoft.public.access.tablesdbdesign
Jeff Boyce
external usenet poster
 
Posts: 8,621
Default How do I create a relationship to similar match in Access?

It sounds like a query would work. Since you didn't provide a specific
example of the values, it's a bit hard to offer a specific suggestion.

If your query looked for values in table2 where the value from table1 was =
MinimumValue and =MaximumValue, would that work?

Regards

Jeff Boyce
Microsoft Office/Access MVP

"Joana Villas-Boas" wrote in
message news
I have a table with minimum and maximum values to find out the ideal weight
for each heigth of the Client's Table.

I wan't to put the client hight and need access to Lookup on the other
table
wich is the ideal weight for that person.

I am an expert in all sort of relationships, but don't know how to do this
one once it is not a direct relationship, it works more like the Lookup
function in excel.

Is this possible in Access?



  #3  
Old November 24th, 2008, 12:23 AM posted to microsoft.public.access.tablesdbdesign
Joana Villas-Boas
external usenet poster
 
Posts: 6
Default How do I create a relationship to similar match in Access?

Thank you Jeff,

I already tried the query and it works fine, now I need to find out how to
make it work on the client's form.

When I have a new client and I input his weight and heith, the ideal weight
is supposed to appear on another field. I can't have that query on the source
of my form. I must figure out another way..

I will sleep on that next issue, maybe you know some way around that too?

Thank you again,

best reagrds,

Joana

"Joana Villas-Boas" wrote:

I have a table with minimum and maximum values to find out the ideal weight
for each heigth of the Client's Table.

I wan't to put the client hight and need access to Lookup on the other table
wich is the ideal weight for that person.

I am an expert in all sort of relationships, but don't know how to do this
one once it is not a direct relationship, it works more like the Lookup
function in excel.

Is this possible in Access?

  #4  
Old November 24th, 2008, 03:56 PM posted to microsoft.public.access.tablesdbdesign
Jeff Boyce
external usenet poster
 
Posts: 8,621
Default How do I create a relationship to similar match in Access?

Joana

So, it sounds like you're saying that after you update the controls with
height and weight, you want the calculated (looked-up) value to show in a
(hopefully-unbound) textbox on the form?

You could add a procedure to the form that first checks to see that both
values are entered, uses either a query or DLookup() function to get the
looked-up value, and fills the textbox with the value. You could then call
that function in the AfterUpdate event of each control, plus add another
call when the form gets an existing record (OnCurrent).

Regards

Jeff Boyce
Microsoft Office/Access MVP

"Joana Villas-Boas" wrote in
message ...
Thank you Jeff,

I already tried the query and it works fine, now I need to find out how to
make it work on the client's form.

When I have a new client and I input his weight and heith, the ideal
weight
is supposed to appear on another field. I can't have that query on the
source
of my form. I must figure out another way..

I will sleep on that next issue, maybe you know some way around that too?

Thank you again,

best reagrds,

Joana

"Joana Villas-Boas" wrote:

I have a table with minimum and maximum values to find out the ideal
weight
for each heigth of the Client's Table.

I wan't to put the client hight and need access to Lookup on the other
table
wich is the ideal weight for that person.

I am an expert in all sort of relationships, but don't know how to do
this
one once it is not a direct relationship, it works more like the Lookup
function in excel.

Is this possible in Access?



  #5  
Old November 24th, 2008, 11:03 PM posted to microsoft.public.access.tablesdbdesign
Joana Villas-Boas
external usenet poster
 
Posts: 6
Default How do I create a relationship to similar match in Access?

That's exactly what I want to do and I thought about the Dlookup function,
but the Lookup Table it's a bit complicated once it has a max and min Heith
and Max and Min Age for each Ideal Weight. I dont' know how to do the Dlookp
with so many fields to lookup into!

I did what you suggested with the Query and it works fine, the problem is
the form is not updatable because there are no relationships between the
client and the ideal wheight table!

Thank you anyway, you helped a lot.

Joana

"Joana Villas-Boas" wrote:

I have a table with minimum and maximum values to find out the ideal weight
for each heigth of the Client's Table.

I wan't to put the client hight and need access to Lookup on the other table
wich is the ideal weight for that person.

I am an expert in all sort of relationships, but don't know how to do this
one once it is not a direct relationship, it works more like the Lookup
function in excel.

Is this possible in Access?

  #6  
Old November 25th, 2008, 06:27 PM posted to microsoft.public.access.tablesdbdesign
Jeff Boyce
external usenet poster
 
Posts: 8,621
Default How do I create a relationship to similar match in Access?

Please note that it is rarely necessary to store a looked-up value if you
can re-calculate it.

Regards

Jeff Boyce
Microsoft Office/Access MVP

"Joana Villas-Boas" wrote in
message ...
That's exactly what I want to do and I thought about the Dlookup function,
but the Lookup Table it's a bit complicated once it has a max and min
Heith
and Max and Min Age for each Ideal Weight. I dont' know how to do the
Dlookp
with so many fields to lookup into!

I did what you suggested with the Query and it works fine, the problem is
the form is not updatable because there are no relationships between the
client and the ideal wheight table!

Thank you anyway, you helped a lot.

Joana

"Joana Villas-Boas" wrote:

I have a table with minimum and maximum values to find out the ideal
weight
for each heigth of the Client's Table.

I wan't to put the client hight and need access to Lookup on the other
table
wich is the ideal weight for that person.

I am an expert in all sort of relationships, but don't know how to do
this
one once it is not a direct relationship, it works more like the Lookup
function in excel.

Is this possible in Access?



 




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 12:58 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.