Skip to main content

Notifications

Dynamics 365 Community / Forums / Finance forum / Cannot read a record i...
Finance forum
Answered

Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.

Posted on by 109
Hi,
I'm getting the following error when opening the form. A new field was added to it and problem started to occur in our test environment (tier-1). However the same form work fine in development env (tier-1). 
Build package was successfully build and installed. I have also run manually dbsync without problems and restarted services on virtual machine.
 
Any ideas how to solve the problem? 
Reset usage data didn't work either (I noticed the same error message in old AX posts and that was suggested as a fix).
  • CU14050742-1 Profile Picture
    CU14050742-1 2 on at
    Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.
  • Verified answer
    Migi Profile Picture
    Migi 109 on at
    Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.
    This was related to the problem that there were field(s) removed in one deployable package and then recreated in next package and it caused this problem - that is now fixed. I'm sure it works in the next environment I'm gonna publish.
  • Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.
    I think you can check this link to find answers for yourself
    https://dynamics365musings.com/candy clicker/how-to-connect-to-a-test-d365-database/
  • Migi Profile Picture
    Migi 109 on at
    Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.
    Thank you all for the replies. I'll update here the solution (if we manage to solve this)
  • Layan Jwei Profile Picture
    Layan Jwei 3,282 Super User on at
    Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.
    Hi Migi,
     
    If it's "not null" in other environments, then Can you please try and deploy the package again on your test environment?
     
    Thanks,
    Layan Jweihan
    Please mark this answer as "Verified" if it solved your issue. In order to help others who will face a similar issue in the future
  • Suggested answer
    Navneeth Nagrajan Profile Picture
    Navneeth Nagrajan 1,231 on at
    Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.
    Hi Migi,
     
    Looks like the field was created successfully in D365 FO but the db sync created a field with null type instead of field with the right types. It should created a field with nvarchar, int or bigint etc. in SQL. Looks like it created a field with null types. Have you checked the same?
     
    Thanks,
    Navneeth.
    If this helped, please mark it as "Verified" for others facing the same issue
  • Suggested answer
    Mohamed Amine Mahmoudi Profile Picture
    Mohamed Amine Mahmoudi 4,565 User Group Leader on at
    Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.
    Hi @Migi,
     
    I think you must flow these steps :
    1. delete the field from table in AOT
    2. build + synchro DB
    3. re-add the field to table
    4. build + synchro DB
     
    Best regards,
    Mohamed Amine MAHMOUDI
  • Migi Profile Picture
    Migi 109 on at
    Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.
    I was managed to fix the problem temporarily by manipulating database:
    UPDATE [dbo].[table]
       SET [field] = ''
     WHERE [field] is null
    GO
     
    However it breaks again if new record is created because it gets null value. I checked with SSMS the field in table and it looks like this:
    [fieldname] (nvarchar(10), null)
     
    The really strange this is that when I deployed the same package to another environment, it worked there and the field looked like this:
    [fieldname] (nvarchar(10), not null)
     
    Now I don't know if it's safe to put this into production because it might work or not. I'd like to fix it via development but don't know if there's a property that affects this null value?
  • Suggested answer
    Waed Ayyad Profile Picture
    Waed Ayyad 2,689 on at
    Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.
    Hi,
     
    if you know which field has null issue, try to fix it from the DB using select statement, in order to access the Test DB, you can check the below link:
     
     
     
    Thanks,
    Waed Ayyad
     
    If this helped, please mark it as "Verified" for others facing the same issue
     
  • Suggested answer
    Deepak Agarwal Profile Picture
    Deepak Agarwal 127 on at
    Cannot read a record in XXX(XXX). An unsupported NULL value has been selected from the database.
    Hello, 
     
    Whats this table by any chance is it a parameter table and whats the property of this new field, like mandatory etc. Did you try to debug this at form or table level. 
     
     

Helpful resources

Quick Links

Contextual content recommendations & SharePoint Q&A

Instantly access relevant sales materials…

Beyond the DRA Cloud Label Printing

Explore cloud-based label printing within Dynamics 365…

HR Infrastructure Customer merge

Important considerations for HR Customer migrations…

Leaderboard

#1
Andre Arnaud de Calavon Profile Picture

Andre Arnaud de Cal... 283,418 Super User

#2
Martin Dráb Profile Picture

Martin Dráb 223,760 Super User

#3
nmaenpaa Profile Picture

nmaenpaa 101,142

Featured topics

Product updates

Dynamics 365 release plans