473,545 Members | 2,003 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Want to update a junction table via forms page

2 New Member
I have created a junction table so that I can relate data from 2 other tables.

Table 1 - Category Table (has the following fields with data)
CatID (primary key)
CategoryName
CategoryStatus

Table 2 - Names Table (has the following fields with data)
NameID (primary key)
Names
NamesStatus

Table 3 - Junction Table (has the primary keys from Tables 1 & 2 - input manually)
CatID
NameID

If I update the Junction table manually it works but I want to be able to use Access Forms to select the CategoryName and the Names fields from the 2 tables and the application be able to save the primary keys in the junction tables.
Mar 13 '07 #1
1 3591
MMcCarthy
14,534 Recognized Expert Moderator MVP
Even though you have created a junction table the relationship between the two tables is still many to many and as such cannot be displayed on one form. You will need to create a main form and a subform.

For example ...

Main form based on the Category Table and subform based on the following query.
Expand|Select|Wrap|Line Numbers
  1. SELECT CatID, Names.NameID, Names, NamesStatus
  2. FROM Junction INNER JOIN Names 
  3. ON Junction.CatID=Names.CatID;
  4.  
Mary
Mar 13 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

1
4044
by: mksql | last post by:
As an example, I am building an authentication mechanisim that will use data in the 3 left tables to determine rights to objects in a destination table, diagrammed below. In this structure, multiple records in the left tables will point to multiple records in the right table. Normally, I would approach this problem using junction tables...
4
2275
by: HEATHER CARTER-YOUNG | last post by:
Please help. I have two databases - one I'm designing that will be our in-house data mgmt system (db1) and another that is a federally-mandated system (db2). We must submit data from db2 but don't want to use this db for our data mgmt needs. Some of the fields in db1 are shared with db2 but the structure and field names are different. When I'm...
1
1800
by: Riley DeWiley | last post by:
I have an application with two tables, A and B. Each has an autonumber unique ID field, plus other data. I have a junction table, AB, containing fields AID, BID, and Count (a number). AB has a combined unique key comprising AID and BID, that is, any combination of the two must be unique, even though any given AID or BID may exist in many...
2
2866
by: Joe Fetters via .NET 247 | last post by:
Have googled and read the VS.NET documentation can't seem to getthe answer to the following. Environment: Framework 1.1 VB.NET WinForm Access database Using all automagic tools (DataAdapter Wizard with generatedDataset and generated Select, Update, Insert and Deletecommands, controls bound to DataSet using the AdvancedDatabinding...
7
1809
by: gthompson | last post by:
Is this possible: Read fields(rows/columns) from one sql database table (TableA). Then edit/update the same 'field' in TableA; and in TableB edit/update a different field - all at the same time? This is the current situation in an Access Form using Sql for the backend. We would like to convert this Access Form to a Web Form using Visual...
2
2915
by: explode | last post by:
I made nova oledbdataadapter select update insert and delete command and connection veza. dataset is Studenti1data, I made it by the new data source wizard,and made datagridview and bindingsource draging Table1 to Form2. The select command works fine, but when I change the data and call update command I get a syntax error: ...
3
2409
by: inthemix | last post by:
My goal is to have a sub-form located on the main form which containts a listbox. The user will be able to select anany number of offices (by officeName) from this listbox. IMO the design is very sound, in 3NF. I just can't figure out how to get the listbox control to work as desired. Table 1 - Applicant Table 2- Interest (Junction)...
1
2695
by: bg_ie | last post by:
I'm designing a database with 3 tables called Function, Test and Scene. A Function has multiple Tests, but a Test has only one Function. A many to many relationship exists between Test and Scene therefore I need a junction table between these two tables - giving 4 tables in total. The Test table would store a foreign key, the primary key of...
1
3000
by: pwebbie | last post by:
In an MS Access Project tied to SQL Server, I am trying to create a data entry form that allows the user to enter info about a law, and then (in a datasheet) edit/insert related web site records (text fields: link title, URL, and description). I have created a main form "law" (text fields in single form) with a subform "links" (text fields in a...
0
7410
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7668
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
7923
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
0
7773
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
5984
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
3466
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3448
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1901
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1025
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.