I think I may have done somthing fundamentally wrong here, but I'm not sure, and I've spent a long time on trying to sort a work-around so I want to see if I can solve this...
Basically my table relationships are thus:
[table A]
|
one-to-many
|
[table B]--one-to-many--[table C]
|
many-to-one
|
[table D]
Basically, table D is a list of journal references ralating to items in Table B. A single journal artical may cover several items in table B.
This all works fine, except when a user needs to edit (via a form) the reference details for an item in table B. For example, if the reference is unknown or unpublished at the point of data input, there will be an "Unpublished" or "Unkown" entry in Table D linking to all such items in table B. If this information is later found, we will need to be able to update this reference for this item only. If you update the reference field from "Unknown" to xyz this will change all the "Unknown" references to xyz.
I've tried to write a work-a-round, whereby after updating the reference, there is a 'save event' which checks if the new reference already exists, and if not it adds it to Table D via SQL, and gives it an ID. The problem is, that when I try and point the item in table B to this ref via this ID I get an error basically saying the ID doesn't exist. If I use me.refresh or doCmd.RunCommand acCmdRefresh, it realises the new ID does exist, but has already commited the changes to the "Unkown" record.
I really feel I'm going way off course with this - it seems to involve a disproportionate amount of coding to try and solve it. Should I just cut my loses and merge Table B and Table D? Or is there a more appropriate way to handle this?
As allways - thanks in advance.
Basically my table relationships are thus:
[table A]
|
one-to-many
|
[table B]--one-to-many--[table C]
|
many-to-one
|
[table D]
Basically, table D is a list of journal references ralating to items in Table B. A single journal artical may cover several items in table B.
This all works fine, except when a user needs to edit (via a form) the reference details for an item in table B. For example, if the reference is unknown or unpublished at the point of data input, there will be an "Unpublished" or "Unkown" entry in Table D linking to all such items in table B. If this information is later found, we will need to be able to update this reference for this item only. If you update the reference field from "Unknown" to xyz this will change all the "Unknown" references to xyz.
I've tried to write a work-a-round, whereby after updating the reference, there is a 'save event' which checks if the new reference already exists, and if not it adds it to Table D via SQL, and gives it an ID. The problem is, that when I try and point the item in table B to this ref via this ID I get an error basically saying the ID doesn't exist. If I use me.refresh or doCmd.RunCommand acCmdRefresh, it realises the new ID does exist, but has already commited the changes to the "Unkown" record.
I really feel I'm going way off course with this - it seems to involve a disproportionate amount of coding to try and solve it. Should I just cut my loses and merge Table B and Table D? Or is there a more appropriate way to handle this?
As allways - thanks in advance.