web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Moving an entire layer from USR to VAR

(0) ShareShare
ReportReport
Posted on by

Hi all

My company have taken over a customer whose customizations are all made in the usr-layer. We are planning to upgrade them to a 2009-version and in this connection I would like to have all their customizations moved to the VAR-layer and subsequently make a dataupgrade (from 3.0 to 2009).

 So my questions are:

What is the best way to move an entire layer to another layer ( here usr to var)

What can I expect of a data upgrade if I want to move data from one installation in usr to another in var?

Best regards,

Steffen

*This post is locked for comments

I have the same question (0)
  • Community Member Profile Picture
    on at

    Hi Steffen

     At first filter all usr objects in a project.Then export the project(usr).Go to appllication folder and rename the axusr.aod.Then import the project(usr) / usr object into var layer.

    Data Upgrade:

    1. Data migration steps
     Prepare the Microsoft Axapta 3.0 test environment by doing the following:1.     or information on installation. Installation of an Axapta 3.0 system consists of the    following:·         Application installation·         Application Object Server installation·         Client installation2.     Back up the Axapta 3.0 database in your production environment, and restore it to the Axapta 3.0 system in your test environment 3.     Copy the application files (*.aod, *.ahd, *.ald, *.add, *.khd) from all layers above the DIS layer from your Axapta 3.0 system. These layers are the modified 3.0 layers. Copy the application files to your Axapta 3.0 system in your test environment. 2. Clean up data Remove data in the Microsoft Axapta 3.0 database that is not needed for audit trails, and that is slowing down performance or making the database unnecessarily large. Before you upgrade your database, select the type of data that you want to clean up by using the standard filtering mechanism.1.     Start Axapta 3.0 in your test environment (Start > All programs > Navision Axapta) and log on.2.     Open the Application Object Tree (AOT).3.     Under \Menu Items\Action, open and run the following forms to clean up the respective types of data:·         SysUserLogCleanUp·         SysDatabaseLogCleanUp·         ProdJournalCleanUp·         InventJournalCleanUp·         ProdTableCleanUp·         SalesParmCleanUp·         PurchParmCleanUp·         LedgerJournalCleanUp  3. Left justify tables Left justify some or all tables in the Axapta 3.0 system. Do this to properly upgrade the database, because in Microsoft Dynamics AX all Microsoft shipped layers have left justified fields and data types only:1.     Start Axapta 3.0 in your test environment (Start > All programs > Navision Axapta) and log on.2.     Open the Application Object Tree (AOT).3.     Click the Import icon.
    The Import window appears.
    4.     In the File name field, enter \AX2009 DVD\DatabaseUpgrade\PrivateProject_LeftJustified.xpo and click OK.
    This creates a project called LeftJustified.
    5.     Click the Project icon, and open Private > LeftJustified (usr).6.     In Project LeftJustified, right-click MainJob (usr) and select Open.
    An Infolog appears stating how many records have been inserted, and the Left Justify form appears.
    7.     In the Left Justify form, select the base type for the fields to left justify.
    This creates a list of tables and columns that are presently right justified.
    8.     To left justify individual tables, select the row and click Left Justify
    - or -
    To left justify all the tables in the base type, click Left Justify All.
     4. Prepare database for Record Identification type changes Import and run the UpgradeColumnList.xpo in the Axapta 3.0 system in the test environment. Do this to prepare the 3.0 database for RecID-type changes from 32 bit integer to 64 bit integer:1.     Start Axapta 3.0 in your test environment (Start > All programs > Navision Axapta), and log on.2.     Open the Application Object Tree (AOT).3.     Click the Import icon.
    The Import window appears.
    4.     In the File name field, enter the path to your installation CD and \ AX2009 CD\DatabaseUpgrade\PrivateProject_UpgradeColumnList.xpo and click OK.5.     Open the AOT and click Forms > UpgradeColumnList.6.     Right-click UpgradeColumnList and select Open.  7. Click Generate, and wait until the operation is complete.
    This could take up to two minutes. This job identifies the record identification and transaction identification fields that are based on the recId and on the TransactionId data type. Fields that contain transaction identification or record identification references but are incorrectly based on the int data type are not identified by the job.
    Such incorrectly typed Axapta 3.0 fields can be handled in one of the following ways:
    ·         Append the list of such fields to the internal list of known incorrectly typed Axapta 3.0 fields of the same type that are hard-coded in the cleanup() method (UpGradeColumnListGenerator class). Then run the UpgradeColumnList job again to have the database updated.·         Manually update the int data type in Microsoft Dynamics AX after the upgrade checklist has been executed.Close Axapta 3.0.  Hope this will solve your problem RegardsAbhishek

     

  • Community Member Profile Picture
    on at

    Hi Abhishek

    First of all, thank you for your reply. As far as I can tell you want me to make an export of all the customized elements of the 3.0 application and then rename the usr-layer aod file and then import the project to the var-layer of the 3.0 installation, is this correct?

    If this is the way to do it, then the data migration process is well known to me, but thank you for the reminder :-)

     Best regards,

    Steffen

  • Rajdip Das Profile Picture
    3,333 on at

    Hi Steffen,

    I think here is two possible ways.....

    1.  You at 1st logged in Ax 3.0 in USR layer mode & then export all the USR Layer customised objects. After completing export then you have to delete all the USR Layer Objects from AOT or Project. After completing this procedure you will log in again in AX 3.0 in VAR layer mode. Here, you import all the objects those you are exported prevoiusly. This procedure will convert your code USR layer to VAR layer. Right now your all customisations are in VAR Layer. There is no customisation in USE layer. And, now you can import the 3.0 application into 2009 application file & then you can deploy it as per the procedure. Now your 2009 and 3.0 applications does not have any USR layer code.

    2. Another way is you can copy all the AX 3.0 application lin AX 2009 application folder. Then you have to log in AX 2009 in USR Layer mode & run Upgradation project. Upgradation project is created under the private folder with AX User layer Customised objects. Here you have to export all the objects or project & after completing export then you have to delete all the USR Layer Objects from AOT, then log off the AX 2009. Re-Log in again 2009 in VAR Layer mode. Import all the objects those were exported.Now you dont have any USR layer customisation, all are converted into VAR layer. Hope it will help u.... :)

     

     

  • Community Member Profile Picture
    on at

    Hi Steffen

     There are different ways to Moving an entire layer from USR to VAR.

    I have done the same problem ,as I have mentioned previously.

    Another way : Import the USR object(AX3.0) in AX 2009 . Create an Upgrade Project in AX 2009 in USR layer.Export the USR object . Import USR object (AX 2009) in VAR layer(AX 2009).

    Try this ,I think this will also helps u.:-)

     

     

    Regards

    Abhishek Bhattacharya

    Kolkata

    India

  • Community Member Profile Picture
    on at

    Hi again

    Yes, this was actully my plan - to code upgrade the 3.0 layers and do the usr-layer export from 2009 and import it to the 2009 var layer.

    My next concerns is with the dataupgrade - will data from 3.0 be mapped to 2009 through tablenames and fieldnames or through tablenums and fieldsnum?

     /Steffen

  • Community Member Profile Picture
    on at

    Hi Steffen,

    As the other posters suggest, you can simply export all of the USR layer objects, and delete them from the USR layer while logged in the USR layer. You can then import the project into the VAR layer, while logged into it.

    However, this is one major caveat. You cannot simply delete tables from the USR layer. This will cause AX to synchronize the database, and drop your tables from the database. YOU WILL LOSE YOUR DATA.

    One way to approach moving your tables to the VAR layer is to do the following.

    1. While logged into the USR layer, rename your USR layer tables (ie. Table1 --> DEL_Table1, Table2 --> DEL_Table2, etc.).
    2. After all the tables have been renamed, synchronize the database. The rename causes AX to create new tables with a copy of the data, but the original tables continue to exist in the AX database. Synchronization will force AX to remove the original tables, that no longer exist in the AOT, from the database. Try browsing your renamed tables. You may get errors. If you do, you may have to manually synchronize each renamed table. I tried this procedure in AX 4.0 SP2, and had to manually synchronize each table. May be different in your version.
    3. Log into AX in the VAR layer.
    4. Right-click each of the renamed table and select "Duplicate".
    5. Rename the duplicate tables to the original names (ie. CopyOfDEL_Table1 --> Table1, etc.).
    6. After you rename the duplicate tables, synchronize the database. Again you may have to synchronize each table manually.
    7. Write the scripts (I would do it in AX) to copy the data from the DEL_Table1 in the USR layer to Table1 in the VAR layer.
    8. Once your satisfied that the data has been moved correctly to the duplicated tables in the VAR layer, and that your business logic continues to work, then you can delete the original, renamed USR layer tables.

    Things to keep in mind:

    1. BACKUP YOUR DATABASE before you do any of the above. 
    2. Were the original USR layer tables reference in other tables by their TableId's and RecId's. If they were, then you have to update those references with the new TableId's and RecId's.
    3. TEST TEST TEST.

    If anyone has other less painful ways of doing this, please share your techniques. --Tom

  • Community Member Profile Picture
    on at

    Hi Tom

    The steps you describe are quite cumbersome, but it appears the once the installation has been up and running in the usr-layer, it's the only way to move exsisting data to a new layer.

    Thanks for your reply.

     /Steffen

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans