Jumat, 03 Februari 2017

RE: [MS_AccessPros] Append Query Does not work

 

OK, this is embarrassing but I think I figured out what the problem is.  And had I provided complete info in the beginning, you would have likely told me what the problem is.

My tblProductFamilies actually has another field.  I left it out of the discussion thinking I would "keep the discussion simple". The additional field is ProductLineID (the product family can be in one of eight or so product lines).  I have that field "required" property set to NO, and that is all I had considered when getting the key violation message, so I wrongly assumed it could not have anything to do with the inability to append records.

However, I have a many to one relationship set for that field and the lu_tblProductLines, ProductLineID field, with referential integrity enforced. 

So this leaves me in a dilemma for which I need some advice.  I have this large Excel spreadsheet, and there will be others to come later which are similar, and in this large flat file amongst other data, is a list of tanks and products in those tanks.  I need to get "new" products (any that are not currently in my lu_tblProductFamilies) from that file.  Any new products are obviously not yet related to a ProductLine record. 

What is the best way to handle this?
1. delete the relationship between ProductFamily and ProductLine?
2. In the Append query just assign all the new products to an "Other" product line and manually correct them later?
3.  some other choice?

Choice 2 seems like the best option to me. 

__._,_.___

Posted by: david.pratt@outlook.com
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (17)

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___

Tidak ada komentar:

Posting Komentar