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

 
 
Опции темы Поиск в этой теме Опции просмотра
Старый 04.01.2019, 23:18   #1  
Blog bot is offline
Blog bot
Участник
 
22,096 / 768 (70) +++++++
Регистрация: 28.10.2006
powerobjects: Auto-numbering in D365 Customer Engagement Version 9
Источник: https://www.powerobjects.com/2019/01...365-version-9/
==============


There is a new feature in V9 that allows us to define a field type as “auto-number.” As a few Microsoft Dynamics 365 commentators have noted, there is no way as yet to set a field as auto-number from the UI. It must be done using the API.

For more information, see Microsoft’s documentation at: https://docs.microsoft.com/en-us/dyn...ber-attributes.

There are a few installable solutions and external tools available that can do this for you, but that is outside the scope of this blog. Today, we’re talking about some of the things we’ve learned about the behavior of auto-numbered fields when importing data or solutions.
  • Early descriptions of the feature indicated that it was necessary to define a field as auto-number as it was being added to the schema. However, experimentation has shown that it is possible to add the feature to an existing text field. This means that you can add auto-numbering to a text field that already exists in your Org – you don’t need to deprecate the field and use a new one, or go through the tedious process of removing dependencies, dropping the field, re-adding it with the new data type and putting the dependencies back in.
  • V9 Auto-number fields are text fields with an additional property indicating that they are to have auto-numbering applied.
  • Adding this property does not affect any data in existing records. But it does make the field read-only. Any new records will be assigned a value by the built-in auto-number plugin. The auto-number plugin runs pre-create on the creation of a new record.
  • If you import a solution from an Org that has a field defined as auto-number into a D365 Org in which the same field is defined as plain text, it will add that property and the field will be updated to auto-number.
  • However, if you import a solution from an Org that has a field defined as plain text into an Org in which the same field is defined as auto-numbered, it remains auto-numbered and none of the numbering is affected.
  • Importing an auto-numbered field into a new org restarts the numbering sequence for seeding at the default of 1001 for the next added record. This occurs whether it is a new or updated field – it uses the database “sequence” function, and the solution has no awareness of the last used number in the source D365 Org. For more information on this, see the details under Set Seed Value in the Microsoft documentation referenced above.
  • If Imported records have data, they will retain the same value that they are brought in with. If there is no data in the field (either brought in with no data in the CSV or if the field is not present), they will be assigned sequence numbers when imported.
  • There is no guarantee that the numbers applied are unique. If a pre-existing record has a number that will be assigned by the feature at some point in the future, the feature will apply that number. If a record is imported with a value in the sequence number field that is also present in the database, it will generate a duplicate number (unless you defined the auto-number field as an alternate key).
Hopefully, you find these learnings helpful. Don’t forget to subscribe to our blog for more Dynamics 365 tips and tricks!

Happy D365’ing!



Источник: https://www.powerobjects.com/2019/01...365-version-9/
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.
 

Похожие темы
Тема Автор Раздел Ответов Посл. сообщение
powerobjects: Dynamics 365 Customer Engagement Application Portability Blog bot Dynamics CRM: Blogs 0 28.12.2018 22:12
powerobjects: Embedded Intelligence with Email Engagement in Dynamics 365 Blog bot Dynamics CRM: Blogs 0 03.11.2018 02:20
powerobjects: Use Microsoft Flow with Dynamics 365 for Customer Engagement Blog bot Dynamics CRM: Blogs 0 03.10.2018 01:26
powerobjects: Delivering a Better Customer Experience with Dynamics 365 Blog bot Dynamics CRM: Blogs 0 20.09.2018 00:22
powerobjects: Creating Your Customer Care Dream Team Blog bot Dynamics CRM: Blogs 0 18.04.2018 00:16
Опции темы Поиск в этой теме
Поиск в этой теме:

Расширенный поиск
Опции просмотра

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

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

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