StuartBombay
Programmer
I have a company table and a sponsor table. Not all sponsors belong with a company, so I created a company called '*No Company' (asterisk so it will show first in list). My form is based on a query. The form has 2 combo boxes for selecting a record. Company (defaults to '*No Company) and Last Name. Last Name is filtered by Company.
The form is also used to add new sponsor records. My problem is with trying to create a new sponsor in the same company. If '*No Company' is the current company, then when I create a sponsor a new company record called '*No Company' is created.
I would like to add Companies on another form, and add sponsors to existing companies. I'm completely confused right now, any suggestions would be great!
The sql for the query under the form is here:
The form is also used to add new sponsor records. My problem is with trying to create a new sponsor in the same company. If '*No Company' is the current company, then when I create a sponsor a new company record called '*No Company' is created.
I would like to add Companies on another form, and add sponsors to existing companies. I'm completely confused right now, any suggestions would be great!
The sql for the query under the form is here:
Code:
SELECT Sponsors.SponsorID, Company.CompanyID, Sponsors.Active, Sponsors.LastName, Sponsors.FirstName, Sponsors.Address, Sponsors.City, Sponsors.State, Sponsors.ZIP, Sponsors.email, Sponsors.HomePhone, Sponsors.MobilPhone, Sponsors.Notes, Company.CompanyName, Company.CompanyPhone
FROM Company RIGHT JOIN Sponsors ON Company.CompanyID = Sponsors.CompnayID
WHERE (((Sponsors.Active)=True))
ORDER BY Sponsors.LastName;