2 Replies Latest reply: Dec 29, 2016 5:00 AM by Sunny Talwar RSS

    ApplyMap not working while concatenate

    Martin Čevela

      Hi to all,

       

      I have a problem with a simple ApplyMap statement. It is not working properly or rather it is not able to do a match and all values are Null.

      I have the same script for the Full load scenario and the script works. The only difference is that the Incremental load scenario is Concatenating the new retrieved data to the previously stored one. The QVD as well as SQL source has the LicenseTypeKey and/or LicenseTypeCode values in (checked). Thanks for ideas...

       

      //Incremental load scenario

      MAP_LicenseType:

      Add Mapping LOAD

      LicenseTypeKey,

      LicenseTypeCode

      FROM $(sG.SourceDir_DIM)GL_DIM_LicenseType.qvd (qvd);

       

      Concatenate(updserver_d)

      LOAD

      'UP' as FactTypeId,

      DateKey &'|'& 'UP' as LinkId,

      PlatformKey,

      ProductVersionKey,

      ProductLanguageKey, CrackStatusKey,

      CountryKey,

      LicenseTypeKey,

      ApplyMap('MAP_LicenseType',LicenseTypeKey,Null()) as LicenseTypeCode,

      ProductSKey,

      SharepointServerRoleKey,

      LotusDominoServerRoleKey,

      KerioConnectServerRoleKey,

      KerioControlServerRoleKey,

      MSExchangeServerRoleKey,

      DateKey,

      COUNT as #COUNT;

      SQL SELECT ...;

       

      //Full load scenario

      DIM_LicenseType_FR:

      Add Mapping LOAD

      LicenseTypeKey,

      LicenseTypeCode

      FROM $(sG.SourceDir_DIM)GL_DIM_LicenseType.qvd (qvd);

       

      /*updserver_d.qvd Full Reload Start*/

      updserver_d:

      LOAD

      'UP' as FactTypeId,

      DateKey &'|'& 'UP' as LinkId,

      PlatformKey,

      ProductVersionKey,

      ProductLanguageKey, CrackStatusKey,

      CountryKey,

      LicenseTypeKey,

      ApplyMap ('DIM_LicenseType_FR',LicenseTypeKey,Null()) as LicenseTypeCode,

      ProductSKey

             ,SharepointServerRoleKey

            ,LotusDominoServerRoleKey

            ,KerioConnectServerRoleKey

            ,KerioControlServerRoleKey

            ,MSExchangeServerRoleKey

      ,DateKey

      ,COUNT as #COUNT;

      SQL SELECT *...;