Can't add/modify a record in a subform

dafne

Registered User.
Local time
Today, 07:23
Joined
Apr 1, 2017
Messages
41
Hello all,
I come from this thread and perhaps you'll be able to help me.
Basically, I want to analyze sentences according to different semantic features: for instance, in "My mother loves cats", "my mother" is "definite", "referential", "concrete", etc... all at the same time.
I have three tables: tbl_Records (record_ID, record_text), tbl_Features (feature_ID, feature_name) and a junction table called tbl_RecordFeatures (feature_ID, record_ID). I'm uploading a screenshot of my relationship window.
I also have a main form and a subform. The main form shows the record I need to analyze, and the dropdown menu in my (continuous) subform allows me - in theory - to select the features that apply to the example in question, one after the other.
My problem is that I keep getting the error "You can't add or change a record because the associated record is required in the table 'tbl_records'" (the wording may be different in the English version, mine's in French). Would any of you know why this is happening?
The subform's Source is tbl_RecordsFeatures; my subform's combo box's Source is feature_I and its Row Source is the query SELECT tbl_Features.feature_ID, tbl_Features.feature_name FROM tbl_Features. Master field is "record_ID" from tbl_Records and Child field is "record_ID" from tbl_RecordsFeatures.
I can upload a sample DB if needed.
Ultimately, I want to calculate a score based on the features selected (which are 12 in total): 0-3 is low salience, 4-8 is medium and 9-12 is high.
Thank you in advance,
Dafne
 

Attachments

  • relationships.png
    relationships.png
    25.7 KB · Views: 172
you do not need to link ,tbl_FEATURES.
this is a LOOKUP table that feeds, tbl_RecordsFeatures.

It should not be part of the relationship. Remove the link.
You only need to relate ownership.
1 Record owns many RecordFeatures. (not the table that feeds it)
 
you do not need to link ,tbl_FEATURES.
this is a LOOKUP table that feeds, tbl_RecordsFeatures.

It should not be part of the relationship. Remove the link.
You only need to relate ownership.
1 Record owns many RecordFeatures. (not the table that feeds it)

Hi, Ranman! Thanks a lot!
I removed the relationship between tbl_NP_feature's "NP_feature_ID" and tbl_RecordsNP_Features' "NP_feature_ID". I was still getting the error, though, but basing myself on what you said ("1 Record owns many RecordsFeatures") I linked tbl_Record's "record_ID" to tbl_RecordsNP_Features' "NP_feature_ID" instead of "record_ID" (as you can see on the snapshot "new relationship").
The error disappeared, and while tbl_RecordsNP_features is keeping track of the features I pick, it's not keeping track of the records they relate to (I'm uploading a snapshot, too). Can you/anybody help me?
 

Attachments

  • new_relationship.png
    new_relationship.png
    25.7 KB · Views: 108
  • record_problem.png
    record_problem.png
    29 KB · Views: 106

Users who are viewing this thread

Back
Top Bottom