problem in setting null property of a field in navision

jksjks Member Posts: 277
Hello,

I added some more fileds in Customer table available with navision database.

When i try to set 'Allow Null' property for these newly added field by going to Enterprise Manager of sql server, it tooks too much time nearly 1 hour and then it pops up one dialog. In that dialog it lists other table of navision database and gives warning that all these tables will be saved to your database.

What should i do?

Please help.

Comments

  • kinekine Member Posts: 12,562
    NEVER change the properties directly on MS SQL...

    You can use the property "ANSI NULL defaults" on File-Database-Alter-Options" for enabling the NULL values. See help to this option for more info...
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • jksjks Member Posts: 277
    I did so. But it doen't work. Still in sql table 'Allow Null' is unchecked and when i try to insert null value for that field it gives an error that you can't enter null values.

    Thanks for any help.
  • kinekine Member Posts: 12,562
    Ok, I tested it, you are right.

    May be that than helps you the option Maintain defaults, which set default value on all fields in database and than you do not need include all fields in insert statement etc... Navision do not know NULL value. Empty value is the '' (empty string), 0 or 1.1.1753 date...
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • jksjks Member Posts: 277
    I am not inserting data using insert statement. I have created one DTS package in which source is Excel and Destination is Sql table. When i run that DTS package at that time it gives an error that it can't insert null into field of sql table whose 'Allow Null' property is not set.

    Please help.
  • kinekine Member Posts: 12,562
    It is same problem... it will create insert without some fields... you need some default values for fields not inserted from source excel file...
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • DenSterDenSter Member Posts: 8,307
    Changing table design of Navision tables in the Enterprise Manager is all around a bad idea. That's all I have to say about it ;)
  • lzrlzr Member Posts: 264
    Did you find a solution for this?

    I have the same problem
    Navision developer
  • DenSterDenSter Member Posts: 8,307
    Just stay away from the table design in Enterprise Manager, you will never have problems like this.
  • lzrlzr Member Posts: 264
    I created some new tables for a customer. Another supplier is meant to fill these tables with values through SQL. And the supplier is complaining about this NOT NULL property on the fields..

    I told him he should set default values so it should be ok. :wink:
    Navision developer
  • lubostlubost Member Posts: 628
    If your problems persist, you can export these tables via SQL and then import them via Navision by the "right" way to tables not touched with Enterprise manager.
Sign In or Register to comment.