Change company keyword in AX

Hi,
Change company() keyword is used to fetch the data from any company (or) to insert data into other company.

Example:
For suppose there is a requirement where there are multiple companies.
when the user creates a new record in a table the record must be inserted in that particular table in all the companies.
This issue can be worked using Virtual companies. (Using table collections). For virtual companies go through this link.

http://technet.microsoft.com/en-us/library/aa834413.aspx

Instead we can work on this through X++.
Use change company() keyword to change to the company that you want to insert the record. While inserting a new record we have to check whether the current record duplicate doesn’t exist in any other company. For that purpose we can use change company() keyword.

Advertisements

One thought on “Change company keyword in AX

Leave a Reply

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

WordPress.com Logo

You are commenting using your WordPress.com 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