title: How can I use forms in libreoffice base to add/modify data in a many-to-many relationship?
body: <p>I am essentially trying to create a glorified contacts list using LibreOffice Base. Many of our contacts have multiple addresses (office, mailing, home), and sometimes multiple people have the same address.</p>
  <p>I've created a simple contacts table with the Contact ID, Last Name, and First Name. I've created an address table with an Address ID, City, State, etc. I've also created a junction table with Contact ID and Address ID, and connected the three tables using the relationships tool.</p>
  <p>Now I want to add everything into a single form. I watched <a href="https://www.youtube.com/watch?v=GYawYO8u3_s" rel="nofollow noreferrer">this youtube video</a>, which was very helpful, but I want to be able to add new cities instead of only selecting from a pre-established list. So I followed along with the video, but set the columns to &quot;combo box&quot; instead of &quot;list box.&quot; However, when I try that I get an error message:</p>
  <p><a href="https://i.stack.imgur.com/TWoVb.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/TWoVb.jpg" alt="enter image description here" /></a></p>
  <blockquote>
  <p>Error inserting the new record</p>
  <p>SQL Status: 23000
  Error code: -177</p>
  <p>Integrity constraint violation - no parent SYS_FK_94 table: Address Table in statement [INSERT INTO &quot;Contact-Address Junction&quot; ( &quot;Address ID&quot;,&quot;Contact ID&quot;) VALUES ( ?,?)]</p>
  </blockquote>
  <p>I assume there's something obvious that I'm missing, but at this point I'm pretty stuck.</p>
  <p>E: I took more screenshots to show the relationships, tables, and how things connect in the form:</p>
  <p><a href="https://i.imgur.com/SZPojqb.png" rel="nofollow noreferrer"><img src="https://i.imgur.com/SZPojqb.png" alt="enter image description here" /></a><br />
  <a href="https://i.imgur.com/SL4m2Wh.png" rel="nofollow noreferrer"><img src="https://i.imgur.com/SL4m2Wh.png" alt="enter image description here" /></a><br />
  <a href="https://i.imgur.com/xZ52wnL.png" rel="nofollow noreferrer"><img src="https://i.imgur.com/xZ52wnL.png" alt="enter image description here" /></a><br />
  <a href="https://i.imgur.com/79vqbve.png" rel="nofollow noreferrer"><img src="https://i.imgur.com/79vqbve.png" alt="enter image description here" /></a><br />
  <a href="https://i.imgur.com/LlA6Bfu.png" rel="nofollow noreferrer"><img src="https://i.imgur.com/LlA6Bfu.png" alt="enter image description here" /></a></p>