No problem with the capitals - I understand.
I tried a few ideas.
You are really dealing with a specific club and 1 sport, so that simplifies some of the combinations/complications.
If you consider all the players, you have 2 groups.
a) those >=18 (no special reqt's, just record the standard data)
b) those < 18 (these require standard info, and they must have 1 or more parent/guardians)
From an entry point of view,
if person is in group a) then record their info, or update their info as necessary
if person is in group b) then record their specific info/or update as necessary, then
(since parent/guardian is required) - to record the parent / guardian(s)
first see if an existing player >18 is an appropriate parent/guardian
have a form with a listbox for players under18, a listbox for players 18 or older, and a combo (Mum, Dad,Other)
Select the player in group a, the player in group b, and the relationship from the combo and have a button to save the record
I had the following code to save a record
Code:
Private Sub btnSave_Click()
On Error GoTo btnSave_Click_Error
On Error GoTo Err_btnSave_Click
Dim sql As String
sql = "Insert into tblParentGuardian (IsGuardianOf,IsPlayerId,IsRelatedAs,LastUpdateDate) " _
& "Values (" & Me.List0.Value & "," & Me.List2.Value & ",'" & Me.Combo5.Value & "',#" & Date & "#)"
Debug.Print sql
CurrentDb.Execute sql, dbFailOnError
Exit_btnSave_Click:
Exit Sub
Err_btnSave_Click:
MsgBox Err.Description
Resume Exit_btnSave_Click
On Error GoTo 0
Exit Sub
btnSave_Click_Error:
MsgBox "Error " & Err.Number & " (" & Err.Description & ") in procedure btnSave_Click of VBA Document Form_Form1"
End Sub
If the player <18 identifies a parent/guardian who is not a player, them you would insert relevant info in the tblParentGuardian.
Just some thoughts for consideration.
I have attached layouts for tblPlayer and tblParentGuardian and the initial form