Impact of DataPerCompany

Can someone help in listing the issues one might face when you change the property DataPercompany of the tables : GL Account, Customer, Vendor and Item ? If we take the Customer example. When there are cust. ledg. entries in company B and no entries in company A, nothing will stop the delete of the customer from company A. Other issues ?

Yes. You need to add code in i.e. Customer.OnDelete so You encapsulate the test for entries inside a loop where You do changecompany. Thats one thing. Another thing is that You often end up sharing all other tables that are “sorrounding” customers, vendors, items and accounts. Examples of such tables are posting setup, payment terms etc. You must also think of renaming and how it works. If You have payment terms per comapny and rename a payment term, then the code for that payment term won’t be renamed on customers since that table has DataPerCompany=No (or was it the other way round…?). //Lars

Backup and restore come to my mind. You can delete and restore a single company in a live database. You can not, however, import company independent data into a non-empty database. I suppose you would have to empty all these tables manually first. Another issue is security: If a user has access to the table in company A, this is sufficient for accessing the table even if he has no access in other companies. Next thing: Table relations from the company independent table into tables with DataPerCompany=Yes. A given foreign key in the independent table may relate to different data in different companies. For example, if there’s a relation to the customer table, customer 123 might be John Smith in company A, but Joe Doe in company B. If you do a lookup on the customer number, you will get John or Joe, depending on which company you are currently logged in.

This can be very scary - We inherited a customer who was a big user of Inventory, whose previous solution centre had decided it was a good idea to make the Item and Item Ledger Entry tables common to all companies - they did not, however, make the Item Register table common to all companies…which had caused a few problems…[xx(] Fortunately they agreed with us that they needed a bright new shiny Navision system with openning balances to start again! [:D]

You could do it in the old days, but with 3.xx there are just too many linked and detail tables to cover every possibility. Better is just to write some code to keep these tables common in all companies. This is pretty easy. Just create a field in the appropriate SetUp table called “Source Company”. Then mae some changes in the onmodify create delete etc. to make sure that the Item/customer/vendor etc is the same…

Or you could send a e-mail to our NRC. We have a great module which is calles MCS (Multi Company Solution). I can garantee you this will be cheaper then designing it yourselfs. Weha Automatisering B.V. info@weha.nl