Change company keyword in AX

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

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.

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.


One thought on “Change company keyword in AX

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 )

Google+ photo

You are commenting using your Google+ 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 )


Connecting to %s