Backward migration

Home Forums Problems and solutions in GDL Library migration Backward migration

Viewing 6 reply threads
  • Author
    Posts
    • #2039
      Barry Kelly
      Participant

      I can get the forward migration to work OK using the example here … https://gdl.graphisoft.com/gdl-docs/gdl-guide/chapter-9-non-geometric-scripts/the-forward-migration-script/

      But I can’t get the backward migration to work using this example here … https://gdl.graphisoft.com/gdl-docs/gdl-guide/chapter-9-non-geometric-scripts/the-backward-migration-script/

      Yes I have discovered the error in the script – an extra space in the GOSUB name at line 23 … “migrationstepname _BWM”: should be “migrationstepname_BWM”:

      I have tried typing in my target objects GUID in directly instead of the “TO_GUID” but that didn’t work either.

      I am assuming this backward migration script goes in the new (16) object and I have to do nothing in the old (15) object or have I got that wrong?
      I have tried placing in the 15 object also but that didn’t work either.

      I am testing by placing my new object in a 16 file with the 16 library loaded (that does not have the old object).
      Then deleting the 16 library and adding the 15 library (that does not have the new object).
      all I get is a missing object from 16 library.
      Works fine when I go from 15 to 16 – the old object becomes the new one with no problems.

      Can anyone please provide a working example of backward migration?
      I have tried looking at some default GS objects but I would like just a simple example without the parameters (I can sort that bit out).
      I just want it to swap for the old object for now.

      Barry.
      Yes I am using the 15 and 16 versions because my original object was written in 15 and I would like to keep it that way as some of my users still like to use 15 rather than migrating old plans to new versions.

      Versions 6.5 to 22
      Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
      Dell Precision M6800 - i7 4700MQ @ 2.40GHz, 16GB RAM, AMD FirePro M6100 (2GB), Windows 7 64bit

    • #2040
      Gergely Fehér
      Keymaster

      Barry,

      Backward migration script should be written in the “new” library. This migration process starts, when you save a plan to ARCHICAD n-1 version. Then AC iterates on all placed libpart instances and runs the backward migration scripts and changes the data stored in the project file.
      It can’t be done with a simple library change, as it is done in the forward migration.

      Gergely Fehér
      Team Leader, Library Team
      GRAPHISOFT SE

    • #2041
      Barry Kelly
      Participant

      Still no luck.
      I have the backward migration in my 16 object.
      I save the 16 file as a version 15.
      Open it in 15 and of course it still loads the 16 library – new object missing from the version 16 library.
      I remove the 16 library and load the 15 library that only has the old object and nothing – version 16 object reports as missing.

      Even if I have both the old and the new object loaded in the 16 library it isn’t converting the new object to the old one.

      Barry.

      Versions 6.5 to 22
      Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
      Dell Precision M6800 - i7 4700MQ @ 2.40GHz, 16GB RAM, AMD FirePro M6100 (2GB), Windows 7 64bit

    • #2042
      Gergely Fehér
      Keymaster

      Then it seems it will be a script or migration table problem. Please attach a sample element pair, to let me check it. (If you don’t want others to download your complex objects, then create samples please. It is an open forum, to help each other learn from the problems, so objects uploaded will be available for everybody, we won’t delete them.)

      Gergely Fehér
      Team Leader, Library Team
      GRAPHISOFT SE

    • #2043
      Barry Kelly
      Participant

      Here are a couple of test objects.
      The original “15 square” object migrates fine to the “16 circle” object.
      But I can’t go the other way.

      Thanks for the help.

      Barry.

      Attachments:

      Versions 6.5 to 22
      Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
      Dell Precision M6800 - i7 4700MQ @ 2.40GHz, 16GB RAM, AMD FirePro M6100 (2GB), Windows 7 64bit

    • #2045
      Gergely Fehér
      Keymaster

      For the first check I found 2 things:

      1. Migration table shouldn’t contain the new objects ID – just the IDs of the “old” objects – now only “0E7CFEF3-E934-4BB0-A6AF-949DE2230811” ID should be there
      2. You need to add the old ARCHICAD version to the migration table – in your example 15 instead of 0, if you want to migrate back between 15 and 16

      Gergely Fehér
      Team Leader, Library Team
      GRAPHISOFT SE

    • #2046
      Barry Kelly
      Participant

      Great thank you Gergely, that worked.
      And the old 15 object needs to be in a loaded library in the 16 file when saving back as 15.

      Barry.

      Versions 6.5 to 22
      Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
      Dell Precision M6800 - i7 4700MQ @ 2.40GHz, 16GB RAM, AMD FirePro M6100 (2GB), Windows 7 64bit

      • #2047
        Gergely Fehér
        Keymaster

        Barry, you don’t need to load the old library when you saving back. It is just needed when you want to use it in the previous version.

        Gergely Fehér
        Team Leader, Library Team
        GRAPHISOFT SE

        • #2050
          Barry Kelly
          Participant

          I am finding if I don’t have the old 15 object loaded when I save back as a 15 file then there is no conversion and the library report just it as a missing version 16 object.
          But it is late now so I will test it out more thoroughly tomorrow.

          Barry.

          Versions 6.5 to 22
          Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
          Dell Precision M6800 - i7 4700MQ @ 2.40GHz, 16GB RAM, AMD FirePro M6100 (2GB), Windows 7 64bit

        • #2053
          Barry Kelly
          Participant

          OK fresh eyes and mind this morning and it all seems to be working fine.
          16 object is reported missing until I delete the 16 library and replace with the 15 library.
          Then old object is back as good as new.

          Thanks again Gergely.

          Barry.

          Versions 6.5 to 22
          Dell XPS- i7-6700 @ 3.4Ghz, 16GB ram, GeForce GTX 960 (2GB), Windows 10
          Dell Precision M6800 - i7 4700MQ @ 2.40GHz, 16GB RAM, AMD FirePro M6100 (2GB), Windows 7 64bit

Viewing 6 reply threads
  • The forum ‘Library migration’ is closed to new topics and replies.