NAV 2013 - Field error because table relation looks at primary key,

MarcusRB
Member Posts: 40
I have the field "User" which has a table relation to the "User Name" field in the "User" table.
I receive an error when I try to enter the value of the field manually instead of using the lookup form. If I enter a correct User Name, I get the following error:


I think this is because of the primary key in the "User" table, as it is set to the Users "Security ID" which is a GUID.
What I want to know, is if there is a way to fix this small problem.
I could set the "Editable" property of the field to "False", however then one doesn't get the dropdown indicator....
I receive an error when I try to enter the value of the field manually instead of using the lookup form. If I enter a correct User Name, I get the following error:


I think this is because of the primary key in the "User" table, as it is set to the Users "Security ID" which is a GUID.
What I want to know, is if there is a way to fix this small problem.
I could set the "Editable" property of the field to "False", however then one doesn't get the dropdown indicator....
0
Best Answer
-
Check the property of the User field in your table. There are two properties ValidateTableRelation and TestTableRelation in there, both should be set to No. In addition the the validation should be coded in OnValidate trigger.
Double check the TableRelation property - it should be se to User."User Name" but I guess you left only the "User" table in there, without specyfing the "User Name" field, which in fact set the relation to the User."Security ID" field, which is a PK on User table
Check the T91 User Setup how it should be done.
Slawek Guzek
Dynamics NAV, MS SQL Server, Wherescape RED;
PRINCE2 Practitioner - License GR657010572SG
GDPR Certified Data Protection Officer - PECB License DPCDPO1025070-2018-035
Answers
-
Check the property of the User field in your table. There are two properties ValidateTableRelation and TestTableRelation in there, both should be set to No. In addition the the validation should be coded in OnValidate trigger.
Double check the TableRelation property - it should be se to User."User Name" but I guess you left only the "User" table in there, without specyfing the "User Name" field, which in fact set the relation to the User."Security ID" field, which is a PK on User table
Check the T91 User Setup how it should be done.
Slawek Guzek
Dynamics NAV, MS SQL Server, Wherescape RED;
PRINCE2 Practitioner - License GR657010572SG
GDPR Certified Data Protection Officer - PECB License DPCDPO1025070-2018-035 -
Slawek_Guzek wrote: »Check the property of the User field in your table. There are two properties ValidateTableRelation and TestTableRelation in there, both should be set to No. In addition the the validation should be coded in OnValidate trigger.
Double check the TableRelation property - it should be se to User."User Name" but I guess you left only the "User" table in there, without specyfing the "User Name" field, which in fact set the relation to the User."Security ID" field, which is a PK on User table
Check the T91 User Setup how it should be done.
The TableRelation was set correctly (User."User Name"), however I had not set the Validate and Test properties to no.
Thanks for the help!0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions