If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
|
Thread Tools | Display Modes |
#11
|
|||
|
|||
A form I made in access 2007 won't let me ad new records
On Thu, 26 Jul 2007 15:28:01 -0700, Eric
wrote: SELECT Properties.*, Owners.FirstName, Owners.LastName, PropertyManagement.ManagementCompany, [Lease Signing Table].Resident1, Owners.MobilePhone, PropertyManagement.MobilePhone AS MobilePhone_PropertyManagement FROM [Lease Signing Table] INNER JOIN (PropertyManagement INNER JOIN (Owners INNER JOIN Properties ON Owners.OwnerID = Properties.OwnerID) ON PropertyManagement.ManagementID = Properties.ManagementID) ON [Lease Signing Table].LeaseID = Properties.LeaseID; This will almost certainly not be updateable. You're using too many tables! Again... base the Form on a query like SELECT Properties.* FROM Properties ORDER BY some reasonable field; as the Recordsource for the form. If you need to see the owner name and other owner data, put a combo box on the form with a Row Source query like SELECT OwnerID, LastName & ", " & FirstName AS OwnerName FROM Owners ORDER BY LastName, FirstName; Set the column count to 2 and the columnwidths property to 0;1 to store the ID but display the name. You can include multiple fields from PropertyManagement in another combo's row source, and put textboxes on the form =cboPropertyManagement.Column(n) where cboPropertyManagement is the name of the combo box and n is the zero based index of the field you want to see (that is, if the MobilePhone field is the fifth field in the query use (4). John W. Vinson [MVP] |
#12
|
|||
|
|||
A form I made in access 2007 won't let me ad new records
Thanks for all the info. I will try a little redesign and get back to you.
It may take me a while. Thanks again for all the help. "John W. Vinson" wrote: On Thu, 26 Jul 2007 15:28:01 -0700, Eric wrote: SELECT Properties.*, Owners.FirstName, Owners.LastName, PropertyManagement.ManagementCompany, [Lease Signing Table].Resident1, Owners.MobilePhone, PropertyManagement.MobilePhone AS MobilePhone_PropertyManagement FROM [Lease Signing Table] INNER JOIN (PropertyManagement INNER JOIN (Owners INNER JOIN Properties ON Owners.OwnerID = Properties.OwnerID) ON PropertyManagement.ManagementID = Properties.ManagementID) ON [Lease Signing Table].LeaseID = Properties.LeaseID; This will almost certainly not be updateable. You're using too many tables! Again... base the Form on a query like SELECT Properties.* FROM Properties ORDER BY some reasonable field; as the Recordsource for the form. If you need to see the owner name and other owner data, put a combo box on the form with a Row Source query like SELECT OwnerID, LastName & ", " & FirstName AS OwnerName FROM Owners ORDER BY LastName, FirstName; Set the column count to 2 and the columnwidths property to 0;1 to store the ID but display the name. You can include multiple fields from PropertyManagement in another combo's row source, and put textboxes on the form =cboPropertyManagement.Column(n) where cboPropertyManagement is the name of the combo box and n is the zero based index of the field you want to see (that is, if the MobilePhone field is the fifth field in the query use (4). John W. Vinson [MVP] |
|
Thread Tools | |
Display Modes | |
|
|