John O'Malvern
Member
- Local time
- Today, 22:54
- Joined
- Mar 25, 2024
- Messages
- 69
A form to enter a new member's details has stopped working, after adding an intermediate table.
Previously:
now:
(the red squiggles mark fields I know are not needed)
the tblContact_Categories was needed between Contacts and tblCategoryTypes as one contact can have more than one CategoryType (ie qualified on more than one type of vehicle)
I have tried to modify the query on which the input form is based, but cannot get the SQL to work (Access shows syntax errors)
FWIW here is the current SQL:
SELECT Contacts.ContactTypeID, Contacts.[CategoryType ID], [Category Types].[Category Type], Contacts.IAMNo, Contacts.FirstName, Contacts.LastName, Contacts.Address, Contacts.Location, Contacts.City, Contacts.StateOrProvince, Contacts.PostalCode, Contacts.MobilePhone, Contacts.Email, Contacts.MWAMRenewal, Contacts.[Date Joined], [Contact Types].ContactType, Contacts.ObserverID, Contacts.ContactID, Contacts.MemberNo
FROM [Contact Types] INNER JOIN ([Category Types] INNER JOIN (Contacts ON [tblCategoryTypes].[CategoryTypeID] = [tblContact_Categories].[ContactID]) ON [Contact Types].[ContactTypeID] = [Contacts].[ContactTypeID])
i.e.
Any help gratefully received!
Previously:
now:
the tblContact_Categories was needed between Contacts and tblCategoryTypes as one contact can have more than one CategoryType (ie qualified on more than one type of vehicle)
I have tried to modify the query on which the input form is based, but cannot get the SQL to work (Access shows syntax errors)
FWIW here is the current SQL:
SELECT Contacts.ContactTypeID, Contacts.[CategoryType ID], [Category Types].[Category Type], Contacts.IAMNo, Contacts.FirstName, Contacts.LastName, Contacts.Address, Contacts.Location, Contacts.City, Contacts.StateOrProvince, Contacts.PostalCode, Contacts.MobilePhone, Contacts.Email, Contacts.MWAMRenewal, Contacts.[Date Joined], [Contact Types].ContactType, Contacts.ObserverID, Contacts.ContactID, Contacts.MemberNo
FROM [Contact Types] INNER JOIN ([Category Types] INNER JOIN (Contacts ON [tblCategoryTypes].[CategoryTypeID] = [tblContact_Categories].[ContactID]) ON [Contact Types].[ContactTypeID] = [Contacts].[ContactTypeID])
i.e.
SQL:
SELECT Contacts.ContactTypeID, Contacts.[CategoryType ID], [Category Types].[Category Type], Contacts.IAMNo, Contacts.FirstName, Contacts.LastName, Contacts.Address, Contacts.Location, Contacts.City, Contacts.StateOrProvince, Contacts.PostalCode, Contacts.MobilePhone, Contacts.Email, Contacts.MWAMRenewal, Contacts.[Date Joined], [Contact Types].ContactType, Contacts.ObserverID, Contacts.ContactID, Contacts.MemberNo
FROM [Contact Types] INNER JOIN ([Category Types] INNER JOIN (Contacts ON [tblCategoryTypes].[CategoryTypeID] = [tblContact_Categories].[ContactID]) ON [Contact Types].[ContactTypeID] = [Contacts].[ContactTypeID])
Any help gratefully received!