Solved

ODBC--call failed error Access 2016/SQL

Posted on 2016-10-21
6
226 Views
Last Modified: 2016-10-21
Hi

I am having an issue with Access 2016.  When users try to save when they first input details into the emergency contact tab they receive an ODBC call failed error (screen shot attached).  This database has an SQL 2008 R2 back end and I have checked the SQL table and the Surname exists in ServiceUsers so the value is not null.

If a user closes the tab by using the x button in the top right hand corner the details do save to the table.  Is there a way to prevent this error occurring?

Any help would be gratefully received
thanks
H--alpha.JPG
0
Comment
Question by:ernie10
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
6 Comments
 
LVL 49

Expert Comment

by:Vitor Montalvão
ID: 41853631
As the error says you're trying to insert a NULL value in a field named Surname that requires a values (can't be empty). So tell the user to provide a surname so he or she don't receive the error anymore.
0
 
LVL 57
ID: 41853664
<<So tell the user to provide a surname so he or she don't receive the error anymore.>>

 or allow nulls in the field.

Jim.
0
 

Assisted Solution

by:ernie10
ernie10 earned 0 total points
ID: 41853666
Hi Vitor

Thanks for the reply,  I am sorry but I don't quite understand.  

For any new client they set up the Surname before they can get to this stage and it is a mandatory field so can not be null (I have checked in the SQL table and it is showing)  and is saved in the table.

There is no other place to enter a second surname on this table or linked tables.  This is only an issue the first time they try to enter the emergency contact details on that tab.  

Please can you elaborate further.

Many thanks
0
Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

 
LVL 49

Accepted Solution

by:
Vitor Montalvão earned 500 total points
ID: 41853674
For any new client they set up the Surname before they can get to this stage and it is a mandatory field so can not be null (I have checked in the SQL table and it is showing)  and is saved in the table.

 There is no other place to enter a second surname on this table or linked tables.  This is only an issue the first time they try to enter the emergency contact details on that tab.  
Then this might be a bug in the application. Somehow is trying to add a new record with no surname. You may need to debug the code to see it as we don't have access to the code.
0
 
LVL 57
ID: 41853683
One important point:

<<If a user closes the tab >>

 If your using a main form with subforms, be aware that Access saves the main form record as soon as you enter a subform.

 So if they have not filled in the surname on the main form, then try to enter emergency contact details by clicking into a subform, you'd get the error.

 Is that the setup you have or something else?

Jim.
0
 

Author Comment

by:ernie10
ID: 41853771
Many thanks for your help,  I have managed to amend the permission on the surname while keeping the validation that I requrie
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
This article describes two methods for creating a combo box that can be used to add new items to the row source -- one for simple lookup tables, and one for a more complex row source where the new item needs data for several fields.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question