Nav web service doesn't work on a table with similar field names


We are exposing a table object as a Nav web service in Nav 2013R2. We are facing an issue with the web service due to similar field names We tried different mechanisms but couldn’t yet find a solution. Any ideas are welcome.

  • Recently migrated to Nav 2013R2.
  • Two fields in a table object (contact card) have similar names (student status and Student Status). One has an additional space
  • This works fine for Nav functionality
  • However, when we expose this table as web service, it throws an error because of the duplicate field names. Is there any way we could overcome this?

Thank you

Hi Phani,

Welcome to Dynamics User Group. Happy to see you as a member!

I’m sorry I don’t have a direct answer to your problem. Instead I can tell you what I with my many years of experience would do.
If such a technical “glitz” happens, then as a programmer we can do one of two things:

  1. Spend endless time on finding a technical solution to how to work around this error. If this is possible, then fine. If not, then you’ve lost lots of time which your customer will not be happy to pay.
  2. Or, you can find a way to prevent the problem to occur in the first place.

What I would conclude based on your description (your question is surely above average in contain the information needed to understand your problem, thank you for that), that there is a problem if there is only spaces that differs two fields. If you have the time, then make a test in a clean table, to see if you can recreate the problem in a different table. If yes, then report this error through to Microsoft.
But if the problem has not yet been fixed in a newer release, then you cannot most likely not wait for their fix to be released.

So I would take the easy way. Rename your fields in the table, so that they are not (almost) the same. You can still have the field captions stay as they are, so the users will not notice.