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. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
dlookup
I have two tables and two Forms which is as follows
Table & Form 1 1)Item Code Description 10101010 DP1 Table & form 2 2)Item Code Description Amount In the second form there is combo Box if I select one item code which have been allready entered in table 1 the form have to display automaticlly the Description and both Item code and Description have to be recorded in table 2 after saving it. Praveen |
#2
|
|||
|
|||
dlookup
Praveen,
What you are attempting to do violates relational database normalization rules. There is no need to store the description in table 2, it is fully defined in table 1 and associated with the item code. Use a query that links the two tables by their common field to "access" the description for reports and form display. In this case, you can either base your form on a query as described above or use the column property of your combo box to display the description on your form. To do the latter, include the description in the row source, as SELECT Table1.Item Code, Table1.Description FROM Table1 ORDER BY Table1.Item Code; To display the description in a textbox, set its ControlSource property to: =YourComboBox.Column(1) See the following references for information on database normalization: http://www.mvps.org/access/tencommandments.htm ACC: Database Normalization Basics http://support.microsoft.com/?id=100139 http://support.microsoft.com/?id=209534 http://support.microsoft.com/?id=283878 Database Normalization Tips by Luke Chung http://www.fmsinc.com/tpapers/genacc...abasenorm.html Support WebCast: Database Normalization Basics http://support.microsoft.com/default...lurb060600.asp Database Normalization: http://burks.bton.ac.uk/burks/foldoc/35/28.htm 5 Rules of Database Normalization: http://www.datamodel.org/NormalizationRules.html "Understanding Relational Database Design" Document Available in Download Center: http://support.microsoft.com/?id=283698 http://support.microsoft.com/?id=164172 ACC2000: "Understanding Relational Database Design" http://support.microsoft.com/?id=234208 Fundamentals of Relational Database Design: http://support.microsoft.com/?id=129519 Database Deisgn Principles: http://msdn.microsoft.com/library/en...ml/ch04DDP.asp Sprinks "Praveen" wrote: I have two tables and two Forms which is as follows Table & Form 1 1)Item Code Description 10101010 DP1 Table & form 2 2)Item Code Description Amount In the second form there is combo Box if I select one item code which have been allready entered in table 1 the form have to display automaticlly the Description and both Item code and Description have to be recorded in table 2 after saving it. Praveen |
Thread Tools | |
Display Modes | |
|
|