Options

Error in NAV 2018 on Export-NAVData/Import-NAVData

ArmondsArmonds Member Posts: 66
When I try to export company in event viewer I get error: "Data is Null. This method or property cannot be called on Null values"

On import error is: "SqlDateTime overflow. Must be between 1/1/1753 12:00:00 AM and 12/31/9999 11:59:59 PM"

I think in both cases error is raised by the same field or property.

On export error occurs almost immediately, but on import after all data is imported end on the finalization phase.

I tried to check for some exceptions with SQL Profiler, but didn't found anything suspicious.

What could cause this error or how to find/source if it?

Other NAV functionality works without errors, database is synchronized...

Best Answer

  • Options
    ArmondsArmonds Member Posts: 66
    Answer ✓
    I found what caused Import/export error.

    Tables 6701,6703..6705, 6707 from NAV 2009 are replaced with new tables in NAV 2018, but in NAV 2018 this tables TableType != Normal.

    Even after successful synchronization in table "Object Metadata Snapshot" are left obsolete records from NAV 2009 with NULL value in columns Base Metadata and Base Hash, after manually deleting this records import/export works.

    So it's crucial to delete this tables in NAV 2009 before migration to NAV 2018.

Answers

  • Options
    DuikmeesterDuikmeester Member Posts: 304
    Sounds like there is a DateTime field with a value Null. However NAV does not allow that value and could only come from inserting data in Sql directly.
  • Options
    ArmondsArmonds Member Posts: 66
    I also thought so.

    I checked all global tables in SQL but didn't found any date field with NULL.

    And also, if i'm not wrong, in NAV date field are not null by default (except taskscheduler system table)
  • Options
    ArmondsArmonds Member Posts: 66
    Answer ✓
    I found what caused Import/export error.

    Tables 6701,6703..6705, 6707 from NAV 2009 are replaced with new tables in NAV 2018, but in NAV 2018 this tables TableType != Normal.

    Even after successful synchronization in table "Object Metadata Snapshot" are left obsolete records from NAV 2009 with NULL value in columns Base Metadata and Base Hash, after manually deleting this records import/export works.

    So it's crucial to delete this tables in NAV 2009 before migration to NAV 2018.
  • Options
    claudiusapera1992claudiusapera1992 Member Posts: 1
    Hello Armonds!

    I have the same issue on Event Viewer when trying to export navdata. You said that "Tables 6701,6703..6705, 6707 from NAV 2009 are replaced with new tables in NAV 2018", but in NAV 2009 R2 I do not have the tables 6701,6703..6705, 6707 ... it is 6.00.33277 build .. How can I check the tables that bother me? :persevere:

    Thank you and have a great day !
  • Options
    ArmondsArmonds Member Posts: 66
    You can try to look for records with NULL values in "Object Metadata Snapshot" tables "Base Metadata" and/or "Base Hash" columns
Sign In or Register to comment.