Modifying data thru query-based subform

G

genericwmail

I'm going to describe my situation just in case anyone has a better
idea about how I might go about making it more efficient or setting up
a better way for users to access the data. But, generally speaking,
my Access form question is at the very end.

I have two tables created in SQL Server: LOT and AUCTION. They are
separate tables because there is a one-to-many relationship between
these entities: that is, a single LOT can have more than one AUCTION,
like if a winner doesn't pay and the item has to be re-listed in a new
auction. (Business reasons dictate retaining the data on the old
Auction.) The LOT table includes [LotNum] and [Description]; the
AUCTION table includes [eBayNum].

I have a third table, ORDER. Records in this table will be Quotes
(e.g. someone wants to know how much it will cost to ship a LOT or
LOTs) or actual Orders (e.g. when a quote is related to a winning
bidder who now wants the LOT shipped somewhere). Thus, ORDER and LOT
have a many-to-many relationship (sort of like the classic Order-Parts
relationship).

Now, on an Access 2000 form designed for entering and modifying ORDER
records, I plan to have a subform which will list the LOTs that are
associated with the ORDER. I want the subform to display [LotNum],
[eBayNum], and [Description]. This data comes from more than one
table, so the datasource for the subform will have to be a query that
fetches appropriate data from the LOT and AUCTION tables. If a user
sees that a LOT's [Description] field is wrong (e.g. it says that
Lot123 is a "queen bed" when it should say "king bed") can the user
change it in this subform and have it properly save back to the LOT
table?

Basically: If the datasource for a subform is a query that puts
together data from more than one table, then will a user be able to
update data in the subform and have it properly save back to the
underlying tables?

Thanks much for any answers or suggestions,
Whill

(For emailing, don't use the email above. You can use w h i l l
9 6 2 0 5 A-T a o l D-O-T c o m )
 
G

GVaught

Depends on how you construct the query. Many times when using multiple
tables in one query, the query becomes not updateable. Many times adding in
the primary key for each table used will help, in some cases it won't. To
facilitate data entry, you may have to create a main form / subform/ subform
scenario; where the second subform is either related to the 1st subform or
to the main form, and the first subform is related only to the main form.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top