query field not updatable if "new" record but OK if Existing

buratti

Registered User.
Local time
Yesterday, 20:13
Joined
Jul 8, 2009
Messages
234
I recently modified a query, which obviously did something to it because it worked before, but I'll explain in more detail.
My problem is that when I am trying to enter a new record I cannot modify any fields that are "auto populated". By "auto populated" I mean, the query is for an orders form. When I enter the customer ID, it "reads" from the customers table and displays fields from it, like Customer Name, Address, etc. I cannot modify any of those fields from the customers table if it is a new record. If I save the record and go back to it or try to modify an existing record, I can modify any field that I want just fine.

The query is as follows:
Code:
SELECT [Orders Status].[Status Name], [Customers Extended].[Contact Name], [Customers Extended].Address, [Customers Extended].City, [Customers Extended].[State/Province], [Customers Extended].[ZIP/Postal Code], [Customers Extended].[Home Phone], [Customers Extended].[Last Name], [Customers Extended].[First Name], [Customers Extended].Account_Number, [Customers Extended].[Full Name], Orders.*, Orders.Notes, [Customers Extended].Card_Type, [Customers Extended].Card_Number, [Customers Extended].Name_on_Card, [Customers Extended].Cardholders_Zip, [Customers Extended].ExpireMo, [Customers Extended].ExpireYR, [Customers Extended].[File As], [Customers Extended].QBListID, [Customers Extended].EditSequence, Orders.Invoice_Total, [Customers Extended].WalletID, [Customers Extended].balance
FROM ([Orders Status] INNER JOIN Orders ON [Orders Status].[Status ID] = Orders.[Status ID]) INNER JOIN [Customers Extended] ON Orders.[Customer ID] = [Customers Extended].ID;

"[Customers Extended]" is a saved query itself. This is actually the query that I modified before. Before, [Customers Extended] was just a query based on my Customers table that had a few added calculated fields in it.

My customers table was originally a COPY of my customer list from an outside data source (plus a few extra fields revelant to my database) that I was not able to link to. Recent updates from my company software now allows me to "link" directly to its data. So i modified my [Customers Extended] table to "join" my live customer data from my company software with the added fields needed in my access database.

If I open the newly modified [customers extended] query I can add/modify/delete anything just as if it were a local table I am editing directly with no problems at all. Here is the SQL of the [Customers Extended] query: (the actual query is quite long due to many fields being included, so this is just a simplified version)
Code:
SELECT customers.[File As], customers.[Contact Name], TFCustomers.customer_ID AS Account_Number, TFCustomers.phys_addr_phone1 AS [Home Phone], TFCustomers.phys_addr_phone2 AS [Mobile Phone], TFCustomers.phys_addr_street AS Address, TFCustomers.phys_addr_city AS City, TFCustomers.phys_addr_state AS [State/Province], TFCustomers.phys_addr_zip AS [Zip/Postal Code], Customers.Card_Type, Customers.Card_Number, Customers.ExpireYR, Customers.ExpireMo, Customers.Name_on_Card, Customers.Cardholders_Zip, Customers.Notes, TFCustomers.date_started AS [Start Date], TFCustomers.date_ended AS [End Date], Customers.Suspended, Customers.[Restart Date], Customers.[Cancel Reason], TFCustomers.billing_group AS [Bill Group], Customers.[Status ID], Customers.EditSequence, Customers.WalletID, Customers.WalletEntryDate, TFCustomers.Notes_id, TFCustomers.balance, TFCustomers.date_last_payment, Customers.ID, Customers.QBListID, TFCustomers.deleted, Customers.[Full Name], Customers.[Last Name], Customers.[First Name], Customers.Account_Number AS [Act#], TFCustomers.name 
FROM TFCustomers LEFT JOIN Customers ON TFCustomers.customer_id = Customers.Account_Number
WHERE (((TFCustomers.deleted)=0));

Any suggestion why I am unable to edit any fields from my customers table if I am entering a NEW record in the first query listed (not the [customers extended] query?
 
Sorry to reply to my own post, but this is an important issue that I need to correct. I figure that maybe my original post was long and confusing which is why it got no responses, so I will re-describe it now in a simpler manner:

Basically I have an Orders form based on a query. That query consists of 2 tables (Orders and Orders Status) and a query named Customers Extended. That Customers Extended query consists of 2 tables, a table named Customers and a table named TFCustomers.

When entering a new record into the Orders form (or even directly in the query its based on) I can add/delete/modify data in any field in that query EXCEPT fields from the Customers table. Whenever I try to enter/modify data from a field in that table i get a popup error "Field is not updateable".

Now, if I am modifying an existing record (or save the "new" one to essentailly make it existing), I can change/add any data from any fields including those from the customers table that I could not before. Its only on new records before saved, that I cannot add/modify data from Customers table fields.

Please!!! Any Suggestions on what is the problem and how to correct this??? If need be refer to my original post for the SQL of the queries.
Thank You
 

Users who are viewing this thread

Back
Top Bottom