AutoLookup to fill in data automatically

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

Guest

I want to create a multiple-table query to fill in data automatically in one
of my database TABLES and/or its related input FORM. HELP goes only part of
the way to showing how this should be done. I've done the query and assume I
have to define a RELATIONSHIP between the tables. I tried but the data
doesn't fill in, and I get no error messages. Do you have an example
database that shows a LookUp Query and table relationships (and whatever else
is required) to demonstrate how this works? Please?
 
Hi, Robert.
I want to create a multiple-table query to fill in data automatically in one
of my database TABLES and/or its related input FORM.

For the steps on how to do this, please see the tutorial on "How to
'auto-complete' a form, with and without code" by using an autolookup query
to automatically fill in information for new records:

http://www.Access.QBuilt.com/html/forms.html#AutoCompleteForm
I've done the query and assume I
have to define a RELATIONSHIP between the tables.

One _should_ define the one-to-many relationship between the two tables, but
it's not required for this to work. Just make sure that the "Enable
AutoJoin" checkbox is checked (Tools menu -> Options -> Tables/Queries tab),
and the table on "one" side of the relationship has a unique index before
you create the query. Then make sure that there are records in the table on
the "one" side before using the form so that data will automatically
populate the form.

HTH.

Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips.

(Please remove ZERO_SPAM from my reply E-mail address, so that a message
will be forwarded to me.)
 
I want to create a multiple-table query to fill in data automatically in one
of my database TABLES and/or its related input FORM. HELP goes only part of
the way to showing how this should be done. I've done the query and assume I
have to define a RELATIONSHIP between the tables. I tried but the data
doesn't fill in, and I get no error messages. Do you have an example
database that shows a LookUp Query and table relationships (and whatever else
is required) to demonstrate how this works? Please?

You're misunderstanding how relationships work, it seems.
Relationships DO NOT automagically fill in data in a table; they
*prohibit* the addition of incorrect data!

And a Form doesn't "fill in" data either: it's a tool, a window which
lets a user type data into the Form, and thereby loads that data into
tables.

Please explain what data you have and what you are trying to get
"filled in" where. If you want to see an example, open the Northwind
sample database and take a look at the Orders form; it lets you type
in an Order and then fill in the OrderDetails, the items included in
that order.


John W. Vinson[MVP]
 
Back
Top