<?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 Using a Variable to determine Field Name in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555455#M40060</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am trying find a simple method of returning the field/column name where a variable is found within a record eg:&lt;/P&gt;&lt;P&gt;ID | Col2 | Col3 | Col 4 | Col 5&lt;/P&gt;&lt;P&gt;XX1 | abc | def | ghi | jkl&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;XX2 | def | ghi | jkl | abc&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm looking for a script function that would return:&lt;/P&gt;&lt;P&gt;'Col4' or the value '4' when I use the value 'ghi' for ID =XX1&lt;/P&gt;&lt;P&gt;and&lt;/P&gt;&lt;P&gt;'Col3' or the value '3' when I use the value 'ghi' for ID =XX2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have had some success concatenating Col1+Col2+Col3+Col4 and searching for the sub-string start position but as I'm intending to use this as an audit tool with several hundred rules this method is too labor intensive.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm sure it's something easy but couldn't find anything obvious when searching the net.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Luke&lt;/P&gt;</description>
    <pubDate>Tue, 12 Mar 2019 14:29:30 GMT</pubDate>
    <dc:creator>Luke_O</dc:creator>
    <dc:date>2019-03-12T14:29:30Z</dc:date>
    <item>
      <title>Using a Variable to determine Field Name</title>
      <link>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555455#M40060</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am trying find a simple method of returning the field/column name where a variable is found within a record eg:&lt;/P&gt;&lt;P&gt;ID | Col2 | Col3 | Col 4 | Col 5&lt;/P&gt;&lt;P&gt;XX1 | abc | def | ghi | jkl&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;XX2 | def | ghi | jkl | abc&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm looking for a script function that would return:&lt;/P&gt;&lt;P&gt;'Col4' or the value '4' when I use the value 'ghi' for ID =XX1&lt;/P&gt;&lt;P&gt;and&lt;/P&gt;&lt;P&gt;'Col3' or the value '3' when I use the value 'ghi' for ID =XX2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have had some success concatenating Col1+Col2+Col3+Col4 and searching for the sub-string start position but as I'm intending to use this as an audit tool with several hundred rules this method is too labor intensive.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm sure it's something easy but couldn't find anything obvious when searching the net.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Luke&lt;/P&gt;</description>
      <pubDate>Tue, 12 Mar 2019 14:29:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555455#M40060</guid>
      <dc:creator>Luke_O</dc:creator>
      <dc:date>2019-03-12T14:29:30Z</dc:date>
    </item>
    <item>
      <title>Re: Using a Variable to determine Field Name</title>
      <link>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555521#M40067</link>
      <description>&lt;P&gt;I think I would rather transform the crosstable to a normal table-structure and applying the checks on this result. To what is meant see: &lt;A href="https://community.qlik.com/t5/Qlik-Design-Blog/The-Crosstable-Load/ba-p/1468083" target="_blank" rel="noopener"&gt;The-Crosstable-Load&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;</description>
      <pubDate>Tue, 12 Mar 2019 15:54:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555521#M40067</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2019-03-12T15:54:23Z</dc:date>
    </item>
    <item>
      <title>Re: Using a Variable to determine Field Name</title>
      <link>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555550#M40080</link>
      <description>&lt;P&gt;That could be a good solution but would likely result in me producing some very large tables, as I'm currently looking at approximately 2,000,000 records each with 48 fields that's why I have been using the concatenation method.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm sure it would work and may well be a better solution. I was hoping there was a function out there like FieldIndex() but instead of returning row number it produced column number/name.&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 12 Mar 2019 16:34:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555550#M40080</guid>
      <dc:creator>Luke_O</dc:creator>
      <dc:date>2019-03-12T16:34:11Z</dc:date>
    </item>
    <item>
      <title>Re: Using a Variable to determine Field Name</title>
      <link>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555628#M40085</link>
      <description>designing in the way marcus mentioned is the most flexible approach.&lt;BR /&gt;Can i ask why you are worried about 2 million records? generally (if the datamodel is design is decent) 2 mill records is not a problem at all for Qlik.&lt;BR /&gt;</description>
      <pubDate>Tue, 12 Mar 2019 19:20:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555628#M40085</guid>
      <dc:creator>dplr-rn</dc:creator>
      <dc:date>2019-03-12T19:20:29Z</dc:date>
    </item>
    <item>
      <title>Re: Using a Variable to determine Field Name</title>
      <link>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555797#M40200</link>
      <description>&lt;P&gt;It's difficult to say what the best approach for your special audit-checking might be but I assume that a table with just 3 columns with normal fieldvalues by 96 M records performed better as a table with 2 M records but with a quite huge string-concatenation - but it will depend on your requirements.&lt;/P&gt;&lt;P&gt;If your checkings are really independent from the records you could use a check against the symbol-tables which contain the distinct values of the fields.&lt;/P&gt;&lt;P&gt;If you provide some more details what should be checked and why - maybe there are other approaches thinkable.&lt;/P&gt;&lt;P&gt;- Marcus&lt;/P&gt;</description>
      <pubDate>Wed, 13 Mar 2019 08:28:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555797#M40200</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2019-03-13T08:28:54Z</dc:date>
    </item>
    <item>
      <title>Re: Using a Variable to determine Field Name</title>
      <link>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555818#M40201</link>
      <description>Thanks Marcus,&lt;BR /&gt;Loaded the table as suggested this morning seemed to perform similar to concatenation method but, as you say certainly more flexible for analysis and require less scripting per audit rule.&lt;BR /&gt;&lt;BR /&gt;I'm auditing health care data and patient records which is why I hadn't use any really data in my example.&lt;BR /&gt;&lt;BR /&gt;All the best&lt;BR /&gt;&lt;BR /&gt;Luke</description>
      <pubDate>Wed, 13 Mar 2019 09:04:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Using-a-Variable-to-determine-Field-Name/m-p/1555818#M40201</guid>
      <dc:creator>Luke_O</dc:creator>
      <dc:date>2019-03-13T09:04:41Z</dc:date>
    </item>
  </channel>
</rss>

