[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

Duplicate problems

Posted on 2014-02-03
3
Medium Priority
?
186 Views
Last Modified: 2014-02-08
If I am trying to duplicate a Sales order that uses 4 tables , Main (A) and 2 (B and C) tables linked to main.

I can generate a new accountID in A and append the original data to the first Related table to  B This will generate new ID numbers in Table B but there is another Related table C where the ID number has a one to one relationship on the ID numbers on B

How do I append new data to with the correct ID numbers in C table and generate the correct linking ID numbers when they don't exist until the A and B tables are appended
0
Comment
Question by:DatabaseDek
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 39

Accepted Solution

by:
PatHartman earned 2000 total points
ID: 39829487
You can do the inserts using DAO in a code loop and that will give you the ID you need as you insert each B record so you can use it to insert the C record.

One-to-one relationships are extremely rare in the real world especially when the "child" is required so I think you should probably reconsider your schema.
0
 

Author Comment

by:DatabaseDek
ID: 39843859
Hi Pat

The reason for two tables is that I am describing something very complex with the data in the form and I ran out of fields. (Yes all 250 of them)

Do you happen to know if this (250fields) is still a limit in later versions of access? I am still soldiering on with 2002 it's brilliantly simple and like many others I hate that ribbon!.
0
 
LVL 39

Expert Comment

by:PatHartman
ID: 39844155
If you ran out of fields, you almost certainly have one or more repeating groups and should normalize the schema to make it easier to work with.

I have been designing data-centric applications using a variety of databases from VSAM and IMS to DB2 and Oracle and lately Jet/ACE and SQL Server for clients ranging from American Express, Readers' Digest and Boeing to the Government of Kuwait  and in over 40 years have never created a table with more than about a hundred columns.

Yes, the limit still exists with ACE (A2007, A2010, A2013).  There really is no reason to change it.  Databases like SQL Server, et al support more columns because they are used for data warehousing in addition to transactional processing applications.  With data warehouse applications, the data is flattened and denormalized and that is why you will occassionally see tables in a warehouse application with large column counts.

Regarding the interface change with A2007 - The ribbon is clunky but it is usable.  It is the nav pain (sic) that I still object to even after using it for over 7 years.
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question