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

 
 
Опции темы Поиск в этой теме Опции просмотра
Старый 18.05.2011, 19:12   #1  
Blog bot is offline
Blog bot
Участник
 
25,640 / 848 (80) +++++++
Регистрация: 28.10.2006
emeadaxsupport: Using skipDeleteActions with doDelete still calls the delete actions
Источник: http://blogs.msdn.com/b/emeadaxsuppo...e-actions.aspx
==============

Recently we came across an issue where running code like this:

Unit unit;
;
select firstonly forupdate unit where unit.UnitId == 'cl';
unit.skipDeleteActions(true);
unit.doDelete();

This results in the delete still being called on Tables\UnitConvert (via the cascaded delete action on Tables\Unit).

This is because SkipDeleteActions() only works when using a set based operation (like delete_from) - so if you set it when calling delete() or doDelete() (row based operations) it will not make any difference and the delete actions will still be called - instead you need to use delete_from for this skip property to be respected.

Checking the AX kernel source code around these skip properties, we found something related that was interesting - the skipDataMethods() flag is respected for row based operations, but only if skipDatabaseLog, SkipEvents and skipDatamethods have all been set for that table buffer (and for delete() in addition skipDeleteActions must be set). Originally in AX3 this wasn't like this - row based operations just ignored these properties.

--author: Tariq Bell --editor: Tariq Bell --date: 18/05/2011


Источник: http://blogs.msdn.com/b/emeadaxsuppo...e-actions.aspx
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.
 

Похожие темы
Тема Автор Раздел Ответов Посл. сообщение
emeadaxsupport: Users don't want to delete their usage data - but you've redeveloped the form - the solution Blog bot DAX Blogs 0 21.04.2011 22:11
axzaptech: Delete Action Blog bot DAX Blogs 0 07.02.2011 16:11
emeadaxsupport: How to delete orphaned data remained from deleted company? Blog bot DAX Blogs 0 09.12.2010 16:11
Microsoft Dynamics CRM Team Blog: Leveraging bulk delete jobs to manage System Job log records Blog bot Dynamics CRM: Blogs 0 13.11.2008 22:06
Исследование - Как работают разные типы Delete Actions. sguryev DAX: База знаний и проекты 1 10.05.2002 15:46

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

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

Рейтинг@Mail.ru
Часовой пояс GMT +3, время: 14:44.