Pages

Wednesday, November 7, 2012

Update cross reference in batch

In AX 2012 R2 you can update cross reference in batch.

You just need to add the class xRefUpdateIL to a bacth job task.

It seems like a batch task for this is automatically created when doing a full compilation, but I haven't really investigated the details of that. Any comments on that are very welcome.

3 comments:

Malcolm said...

Hi Palle

I'm trying to do this now but not getting anywhere.
If I create a new batch job and manually add a task then go to select the class I get a list which does not include "xRefUpdateIL".

Looking at the code that builds the class list I can see that it needs to be a class that supports batch journals (canGoBatchJournal = true) which isn't the case for this class.

Palle Agermark said...

Somehow the upgrade framework to R2 pushes this class into the batch framework.

I'll see if I can find some time to figure out how it does it.

Palle Agermark said...

In the Main method of the xRefUpdate class, you can see how a batch job is being created.

To add it manually to the batch you, you'd need to write a wrapper though.