<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: creating new dimension using existing data in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098419#M919141</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The same lookup functionality is available in QlikView as Mapping Load and ApplyMap.&lt;/P&gt;&lt;P&gt;Attached the below script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BaseData:&lt;/P&gt;&lt;P&gt;LOAD ACCOUNT, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Description&lt;/P&gt;&lt;P&gt;FROM [..\Downloads\new_dimension.xlsx] (ooxml, embedded labels, table is base);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MapBase:&lt;/P&gt;&lt;P&gt;MAPPING LOAD ACCOUNT, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Description&lt;/P&gt;&lt;P&gt;Resident BaseData Where Left(ACCOUNT,1) = 4;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Concatenate (BaseData)&lt;/P&gt;&lt;P&gt;LOAD ACCOUNT, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ApplyMap ('MapBase',RIGHT(ACCOUNT,7),Null()) as [501-GROUP]&lt;/P&gt;&lt;P&gt;FROM [..\Downloads\new_dimension.xlsx] (ooxml, embedded labels, table is Mapping);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Srini.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 07 May 2016 16:36:54 GMT</pubDate>
    <dc:creator>rrsrini2907</dc:creator>
    <dc:date>2016-05-07T16:36:54Z</dc:date>
    <item>
      <title>creating new dimension using existing data</title>
      <link>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098418#M919140</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a database with few dimensions, among them the ACCOUNT and DESCRIPTION. Among accounts I have those starting from 4xx and those starting from 5xx. the 5xx contain in their string the 4xx ones. As per attachment, there is an account no 401-101 and the 501-00214-401-101. &lt;/P&gt;&lt;P&gt;I would like to create a new dimension in the LOAD script (501-Group), mapping the names of 4xx account to appropriate 5xx ones (and only to 5xx ones, in case of other accounts this dimension should be blank. I did what I want to get in excel, but don't know QV formulas enough to repeat it. could you please help?&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;draszor&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098418#M919140</guid>
      <dc:creator />
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: creating new dimension using existing data</title>
      <link>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098419#M919141</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The same lookup functionality is available in QlikView as Mapping Load and ApplyMap.&lt;/P&gt;&lt;P&gt;Attached the below script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BaseData:&lt;/P&gt;&lt;P&gt;LOAD ACCOUNT, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Description&lt;/P&gt;&lt;P&gt;FROM [..\Downloads\new_dimension.xlsx] (ooxml, embedded labels, table is base);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MapBase:&lt;/P&gt;&lt;P&gt;MAPPING LOAD ACCOUNT, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Description&lt;/P&gt;&lt;P&gt;Resident BaseData Where Left(ACCOUNT,1) = 4;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Concatenate (BaseData)&lt;/P&gt;&lt;P&gt;LOAD ACCOUNT, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ApplyMap ('MapBase',RIGHT(ACCOUNT,7),Null()) as [501-GROUP]&lt;/P&gt;&lt;P&gt;FROM [..\Downloads\new_dimension.xlsx] (ooxml, embedded labels, table is Mapping);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Srini.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 07 May 2016 16:36:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098419#M919141</guid>
      <dc:creator>rrsrini2907</dc:creator>
      <dc:date>2016-05-07T16:36:54Z</dc:date>
    </item>
    <item>
      <title>Re: creating new dimension using existing data</title>
      <link>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098420#M919142</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;According to you issue your script should look like this:&lt;/P&gt;&lt;PRE __default_attr="sql" __jive_macro_name="code" class="jive_macro_code jive_text_macro _jivemacro_uid_14626395873467840" jivemacro_uid="_14626395873467840" modifiedtitle="true"&gt;
&lt;P&gt;mapping_account:&lt;/P&gt;
&lt;P&gt;MAPPING LOAD Account, &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Description&lt;/P&gt;
&lt;P&gt;FROM&lt;/P&gt;
&lt;P&gt;&lt;C&gt;&lt;/C&gt;&lt;/P&gt;
&lt;P&gt;(ooxml, embedded labels, table is Sheet1)&lt;/P&gt;
&lt;P&gt;Where left(Account, 1) = 4;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Data:&lt;/P&gt;
&lt;P&gt;LOAD Account, &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ApplyMap('mapping_account', Right(Account, 7), ':') as Description&lt;/P&gt;
&lt;P&gt;FROM&lt;/P&gt;
&lt;P&gt;&lt;C&gt;&lt;/C&gt;&lt;/P&gt;
&lt;P&gt;(ooxml, embedded labels, table is Sheet1)&lt;/P&gt;
&lt;P&gt;Where left(Account, 1) = 5;&lt;/P&gt;
&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See the attachments.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 07 May 2016 16:46:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098420#M919142</guid>
      <dc:creator>MindaugasBacius</dc:creator>
      <dc:date>2016-05-07T16:46:44Z</dc:date>
    </item>
    <item>
      <title>Re: creating new dimension using existing data</title>
      <link>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098421#M919143</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;MappingTable:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Mapping&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD ACCOUNT, &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Description&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FROM&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;new_dimension.xlsx&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;(ooxml, embedded labels, table is base);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Table:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD ACCOUNT, &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ApplyMap('MappingTable', Right(ACCOUNT, 7), Null()) as Description&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FROM&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;new_dimension.xlsx&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;(ooxml, embedded labels, table is Mapping);&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;IMG alt="Capture.PNG" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/123872_Capture.PNG" style="height: auto;" /&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 07 May 2016 16:48:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098421#M919143</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-05-07T16:48:48Z</dc:date>
    </item>
    <item>
      <title>Re: creating new dimension using existing data</title>
      <link>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098422#M919144</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;by using apply map to give new dimension name or to give load field name as new name resident table name also to get the new dimension&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 08 May 2016 07:58:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098422#M919144</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-05-08T07:58:06Z</dc:date>
    </item>
    <item>
      <title>Re: creating new dimension using existing data</title>
      <link>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098423#M919145</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks a lot for your help. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, it's just to remember that what vlookup() does in excel, Mapping load and ApplyMap() formula does in QV. &lt;/P&gt;&lt;P&gt;I was successful with my task, bus would still have an additional question. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When having Mapping table in a separate excel file, everything works great. The Mapping load has its simple construction of Mapping Load ... From file.path. &lt;/P&gt;&lt;P&gt;However, the original database is loaded from ORACLE database, using the following construction:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;BasicDataLoad:&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;Load *,&lt;/P&gt;&lt;P&gt;&lt;EM&gt;here I create few additional dimensions based on the ones sitting in database&lt;/EM&gt;...&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;SQL Select *&lt;/P&gt;&lt;P&gt;From myDatabase&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In this BasicDataLoad statement all the dimensions needed to do the mapping are loaded. question - is there a way that I use in my Mapping Load (that goes before this BasicDataLoad statement in the script) a reference to this BasecDataLoad as data source, so that I avoid keeping separate excel? I was trying the followng construction:&lt;/P&gt;&lt;P&gt;Mapping Load&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;From BasicDataLoad&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;this does not work. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks for any feedback&lt;/P&gt;&lt;P&gt;Robert&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 May 2016 06:14:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098423#M919145</guid>
      <dc:creator />
      <dc:date>2016-05-09T06:14:46Z</dc:date>
    </item>
    <item>
      <title>Re: creating new dimension using existing data</title>
      <link>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098424#M919146</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;A mapping table consists of two columns, the first containing comparison values and the second containing the desired mapping values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In case you have more than one field to lookup you should use Join statement.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 May 2016 06:19:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098424#M919146</guid>
      <dc:creator>MindaugasBacius</dc:creator>
      <dc:date>2016-05-09T06:19:14Z</dc:date>
    </item>
    <item>
      <title>Re: creating new dimension using existing data</title>
      <link>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098425#M919147</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Robert - &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mapping Load only works with two fields at a time (one which is getting mapped from and the other which is getting mapped from). There are ways to do multiple mapping from one mapping load, but the syntax get a little messy where you need to create a concatenated list of all mapped to field in the mapping load and then use ApplyMap with SubField function. I would argue creating multiple mapping tables for 3-4 different mappings because it is easy to understand. Beyond that you might want to consider doing a join. Join is an alternative to mapping. Between join and applymap, applymaps tends to be considered a little better. &lt;A href="https://community.qlik.com/qlik-blogpost/2756"&gt;Don't join - use Applymap instead&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With regards to mapping from Oracle, you can def. do a mapping load from any database that you may have. Again you need to only have two fields in your mapping load table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this answers all your questions. Let us know if you still have any questions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 May 2016 06:21:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/creating-new-dimension-using-existing-data/m-p/1098425#M919147</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-05-09T06:21:56Z</dc:date>
    </item>
  </channel>
</rss>

