AXForum  
Вернуться   AXForum > Microsoft Dynamics CRM > Dynamics CRM: Blogs
All
Забыли пароль?
Зарегистрироваться Правила Справка Пользователи Сообщения за день Поиск

 
 
Опции темы Поиск в этой теме Опции просмотра
Старый 28.01.2008, 21:23   #1  
Blog bot is offline
Blog bot
Участник
 
25,475 / 846 (79) +++++++
Регистрация: 28.10.2006
If you're in an environment where you have multiple companies setup and each company uses the same items, you might be tempted to share the item table across all companies.


In versions prior to 5.0, you can get away with this since the Adjust Cost process are done using the Item Ledger and Item Application Entry table. When inventory is taken out, it'll use the proper average cost when the Adjust Cost process is ran.


However, in version 5.0, they introduced the Avg. Cost Adjmt. Entry Point table and the Cost is Adjust field on the item card. This means that if if you just share the tables and adjust cost is ran for Company A, it'll mark the Cost Is Adjusted to true. This means that the Adjust Cost process will never be ran for Company B. In addition, when transactions are posted for Company B, it'll look at the Avg. Cost Adjmt. Entry Point table and detect that the cost has not been adjusted and mark it for adjustment again.


The best solution to this problem is to suggest the users to update item information for both companies. However, if the business requirement is to share the Item table, it's recommended that you keep the tables separate. And write a batch process to update items at the end of day or if it needs to be real time, write code to something like:


ItemCompanyB.CHANGECOMPANY('Company B');
IF ItemCompanyB.GET("No.") THEN BEGIN
CostPostedGL := ItemCompanyB."Cost is Posted to G/L";
CostAdj := ItemCompanyB."Cost is Adjusted";
UnitCost := ItemCompanyB."Unit Cost";
ItemCompanyB.TRANSFERFIELDS(Rec);
ItemCompanyB."Cost is Posted to G/L" := CostPostedGL;
ItemCompanyB."Cost is Adjusted" := CostAdj;
ItemCompanyB."Unit Cost" := UnitCost;
IF NOT ItemCompanyB.INSERT THEN
ItemCompanyB.MODIFY;
END;


You can probably write a better code, but you should be able to get the idea. This will also require that all the item master information be entered into one company.



Подробнее... http://dynamicsuser.net/blogs/alexchow/arc...ersion-5-0.aspx
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.
 


Ваши права в разделе
Вы не можете создавать новые темы
Вы не можете отвечать в темах
Вы не можете прикреплять вложения
Вы не можете редактировать свои сообщения

BB коды Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.
Быстрый переход

Рейтинг@Mail.ru
Часовой пояс GMT +3, время: 17:52.
Powered by vBulletin® v3.8.5. Перевод: zCarot
Контактная информация, Реклама.