AX 2012: crossCompany insert_recordset

Although we cannot use crossCompany keyword with insert_recordset command, we can still achieve the same functionality with some performance overhead as follows:

static void JobCCIns(Args _args)
    Table21 tab21;
    Table22 tab22;

    while select crossCompany actionDate, name, dataAreaId from tab21
        where tab21.actionDate > str2Date('1998-01-22', 321)
            tab22 = null;
            tab22.actionDate = tab21.actionDate;

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s