473,471 Members | 1,778 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

MS-ACCESS - Insert Record - Cannot Update Fields Values In Query-Based Form

2 New Member
Hi,

I'm an occasional Ms-Access developer, so there is still a lot of stuff that I don't get...

Right now, I'm working on a database that stores contractual information.

One of the form that I created is based on a query that links several tables.

When I try to insert a record in this query-based form, I can only update the fields that are used to build relations with other tables.

The fields that are not involved in the database relations are simply locked.

However, when I am navigating records, I can update all fields.

So basically, I only have problems when I want to insert a new record.

---New Info:
Here is the query behind the form

SELECT Contract_info.Ctrct_Cpy_ID,
Contract_info.Ctrct_ID,
Contract_info.Ctrct_Ref,
Contract_info.Ctrct_Branch_ID,
Contract_info.Ctrct_Start_Date,
Contract_info.Ctrct_Service_ID,
Contract_info.Ctrct_End_Date,
Contract_info.Ctrct_Duration,
Contract_info.Ctrct_TO_month,
Contract_info.Ctrct_Investment_Y_N,
Contract_info.Ctrct_Investment_Amount, Contract_info.Ctrct_Terms_of_Payment,
Contract_info.Ctrct_Lunch_p_Day,
Contract_info.Ctrct_Lunch_u_price,
Contract_info.Ctrct_BF_p_Day,
Contract_info.Ctrct_BF_u_price,
Contract_info.Ctrct_Diner_p_Day,
Contract_info.Ctrct_Diner_u_price,
Contract_info.Ctrct_Management_Fee,
Contract_info.Ctrct_Nb_Staff,
Contract_info.Ctrct_Staff_u_price,
Contract_info.Ctrct_Scope,
Contract_info.Ctrct_Comments,
StatusContract.Status_Name,
Company_site.Cpy_Code,
Company_site.Cpy_Name_EN,
People.Name_EN,
Branch.Branch_Name,
Branch.Branch_Name_Code,
City.City_Name,
Service.Service,
Service.Description,
People.Position

FROM StatusContract
INNER JOIN (Service
INNER JOIN (Company_site
INNER JOIN (City
INNER JOIN (ADEN_People
INNER JOIN (ADEN_Branch
INNER JOIN Contract_info
ON Branch.Branch_ID=Contract_info.Ctrct_Branch_ID)
ON People.Staff_ID=Contract_info.Ctrct_Sales_ID)
ON City.CityID=Branch.Branch_City_ID)
ON Company_site.Cpy_ID=Contract_info.Ctrct_Cpy_ID)
ON Service.ServiceID=Contract_info.Ctrct_Service_ID)
ON StatusContract.Status_Ctrct_ID=Contract_info.Ctrct _Status_ID;

==> I have exactly the same behavior when I try to add a line in the table resulting from this query


Thanks a lot for your help...

Regards,

Ferasse.
Jan 14 '08 #1
5 10245
epots9
1,351 Recognized Expert Top Contributor
Moved to the Access Forums, where the resident experts can better assist you.

**Moved from Programming Challenges.
Jan 14 '08 #2
MMcCarthy
14,534 Recognized Expert Moderator MVP
Hi Ferasse

The problem is you can only base a data entry form on an updatable query. Not all queries are updatable.

For example if you join two tables where there is a one to many relationship then this query is not updatable. That is there are many records in the second table which are related to one record in the first table. For instance many invoices in tblInvoices to one customer in tblCustomers.

You can't just join these two tables in a query and base a form on them. You need one main form for Customers and use a sub form or popup form to add invoices.
Jan 14 '08 #3
Ferasse
2 New Member
Hi Ferasse

The problem is you can only base a data entry form on an updatable query. Not all queries are updatable.

For example if you join two tables where there is a one to many relationship then this query is not updatable. That is there are many records in the second table which are related to one record in the first table. For instance many invoices in tblInvoices to one customer in tblCustomers.

You can't just join these two tables in a query and base a form on them. You need one main form for Customers and use a sub form or popup form to add invoices.
Thank a lot man...

I could have spent a lot of days in the properties trying all kind of combinations.

Well, thanks again!!!

Ferasse.
Jan 15 '08 #4
MMcCarthy
14,534 Recognized Expert Moderator MVP
Thank a lot man...

I could have spent a lot of days in the properties trying all kind of combinations.

Well, thanks again!!!

Ferasse.
You're welcome.

Mary
(Wo)man :D
Jan 15 '08 #5
dozingquinn
28 New Member
Yes - I was (actually am) facing this problem to - and am trying to rectify it before my partner yells at me for breaking her accounts!

Another good 'trouble-shooter' guide can be found here:

http://allenbrowne.com/ser-61.html

David
Jan 21 '08 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

9
by: CY FOK | last post by:
Hi I am planning to open a software company to develop client-server apps and web applications for my client. Now, i am in a difficult situation to determine what is the best platform i should use...
5
by: Don Wash | last post by:
Hi All! I do not find any relevant newsgroups to post this question so I just posted to this VB DotNet and General DotNet groups. I'm trying to create a VB.NET application that will scan...
18
by: Rob R. Ainscough | last post by:
MS Visual Studio Ad contained in VS Magazine. Two developers in "hip" clothing diagramming out a huge flow chart on a beach. I could NOT stop laughing at the stupidity of the ad -- "Let your...
7
by: Joe Ross | last post by:
I've been working with Microsoft support for over 3 weeks now on an intermittent General Network Error we're seeing in our production environment between our ASP.NET application and SQL Server...
1
by: Ted | last post by:
I managed to get it installed OK, along side MS Visual Studio 2005 (with which I received it). During the install, I made sure I installed everything. I have developed a number of applications...
1
by: Dr T | last post by:
Hi! I downloaded MS Visual Web Developer 2005 Express Edition, MS .NET Framework SDK v2.0, and MS SQL Server 2005. Subsequently, I bought MS Visual Studio 2005 Professional Edition. 1) Are...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.