<?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: use of dynamic variable in chart dimension in Qlik Answers</title>
    <link>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525626#M396</link>
    <description>&lt;P&gt;Hi Thomas, Thanks for your suggestion. The variable is&amp;nbsp;vChartDimension(1).&lt;/P&gt;&lt;P&gt;Here I am passing parameter to this varaiabl;e as the expression is accepting numbers like 1, 2, 3 and based on this it returns the Field Name. Let say it return a field name Prod_1.&lt;/P&gt;&lt;P&gt;This field name can be changed when user select different filter values.&lt;/P&gt;&lt;P&gt;I am using this variable in chart dimension like below:&lt;/P&gt;&lt;P&gt;=$(vChartDimension(1))&lt;/P&gt;&lt;P&gt;It gives error that invalid dimension.&lt;/P&gt;&lt;P&gt;I used your suggestion&lt;/P&gt;&lt;P&gt;'=$(=vChartDimension(1))' but it return blank.&lt;/P&gt;&lt;P&gt;I have used this in If clause and used wildmatch function also but not working. If instead of using this variable I pass field name in wildmatch function, chart is working. I think chart dimension is unable to evaluate the variable.&lt;/P&gt;&lt;P&gt;What is the mapping logic you are talking about. If you can explain it further.&lt;/P&gt;</description>
    <pubDate>Tue, 29 Jul 2025 14:18:21 GMT</pubDate>
    <dc:creator>musketeers</dc:creator>
    <dc:date>2025-07-29T14:18:21Z</dc:date>
    <item>
      <title>use of dynamic variable in chart dimension</title>
      <link>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525596#M393</link>
      <description>&lt;P&gt;Hi, I have a variable which generates a filed name. This value of field name changes based on user filter selection. This field name is there in a table. I need to generate a bar chart and dimension is based on the field name generated by the variable.&lt;/P&gt;&lt;P&gt;I am using this variable in chart dimension but it says invalid dimension. This variable return the valid column name.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could any one please help here.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jul 2025 10:18:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525596#M393</guid>
      <dc:creator>musketeers</dc:creator>
      <dc:date>2025-07-29T10:18:25Z</dc:date>
    </item>
    <item>
      <title>Re: use of dynamic variable in chart dimension</title>
      <link>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525607#M395</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/32513"&gt;@musketeers&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hi, I have a variable which generates a filed name. This value of field name changes based on user filter selection. This field name is there in a table. I need to generate a bar chart and dimension is based on the field name generated by the variable.&lt;/P&gt;
&lt;P&gt;I am using this variable in chart dimension but it says invalid dimension. This variable return the valid column name.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could any one please help here.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/32513"&gt;@musketeers&lt;/a&gt;,&lt;BR /&gt;It sounds like you're passing a field name as a string, but Qlik expects an actual field reference in the dimension. Try using `$(=YourVariable)` in the dimension expression to evaluate the variable dynamically. If that doesn’t work, consider using a calculated dimension or mapping logic to resolve the field name before chart rendering. You’re close—just need to bridge that dynamic gap.&amp;nbsp;&lt;A href="https://www.reddit.com/r/BibleChatAiApp/" target="_blank" rel="noopener"&gt;&lt;FONT size="1 2 3 4 5 6 7"&gt;&lt;FONT color="#FFFFFF"&gt;Bible Chat&lt;/FONT&gt;&lt;/FONT&gt;&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Best Regards,&lt;BR /&gt;Thomas Henry&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Jul 2025 05:36:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525607#M395</guid>
      <dc:creator>thomas598henry</dc:creator>
      <dc:date>2025-07-30T05:36:36Z</dc:date>
    </item>
    <item>
      <title>Re: use of dynamic variable in chart dimension</title>
      <link>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525626#M396</link>
      <description>&lt;P&gt;Hi Thomas, Thanks for your suggestion. The variable is&amp;nbsp;vChartDimension(1).&lt;/P&gt;&lt;P&gt;Here I am passing parameter to this varaiabl;e as the expression is accepting numbers like 1, 2, 3 and based on this it returns the Field Name. Let say it return a field name Prod_1.&lt;/P&gt;&lt;P&gt;This field name can be changed when user select different filter values.&lt;/P&gt;&lt;P&gt;I am using this variable in chart dimension like below:&lt;/P&gt;&lt;P&gt;=$(vChartDimension(1))&lt;/P&gt;&lt;P&gt;It gives error that invalid dimension.&lt;/P&gt;&lt;P&gt;I used your suggestion&lt;/P&gt;&lt;P&gt;'=$(=vChartDimension(1))' but it return blank.&lt;/P&gt;&lt;P&gt;I have used this in If clause and used wildmatch function also but not working. If instead of using this variable I pass field name in wildmatch function, chart is working. I think chart dimension is unable to evaluate the variable.&lt;/P&gt;&lt;P&gt;What is the mapping logic you are talking about. If you can explain it further.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jul 2025 14:18:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525626#M396</guid>
      <dc:creator>musketeers</dc:creator>
      <dc:date>2025-07-29T14:18:21Z</dc:date>
    </item>
    <item>
      <title>Re: use of dynamic variable in chart dimension</title>
      <link>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525716#M397</link>
      <description>&lt;P&gt;In general is a variable usable to define a dimension - the return must just be looking as if the dimension were directly selected respectively be written (it's not mandatory the same).&lt;/P&gt;&lt;P&gt;In your case is something wrong. It might be the parameter which isn't properly specified or something else. You may take something like this as starting point:&lt;/P&gt;&lt;P&gt;var:&lt;BR /&gt;= 'Prod_' &amp;amp; '$1'&lt;/P&gt;&lt;P&gt;call:&lt;BR /&gt;&lt;STRONG&gt;[&lt;/STRONG&gt;$(=$(var(1)))&lt;STRONG&gt;]&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;In the case that the field-name contained any spaces or special chars the return must be wrapped with [] or "" ...&lt;/P&gt;</description>
      <pubDate>Wed, 30 Jul 2025 11:48:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525716#M397</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2025-07-30T11:48:23Z</dc:date>
    </item>
    <item>
      <title>Re: use of dynamic variable in chart dimension</title>
      <link>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525717#M398</link>
      <description>&lt;P&gt;I think it's caused by brackets in variable name. Qlik interprets it as a function (obviously it does not exist) with 1 as argument.&lt;/P&gt;&lt;P&gt;Here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/sense/May2025/Subsystems/Hub/Content/Sense_Hub/Introduction/guidelines-visualizations-fields-naming.htm" target="_blank" rel="noopener"&gt;https://help.qlik.com/en-US/sense/May2025/Subsystems/Hub/Content/Sense_Hub/Introduction/guidelines-visualizations-fields-naming.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;You can find guidelines for naming conventions and characters such as ( ) are reserved.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Anyway, try this as dimension value of your chart:&lt;/P&gt;&lt;P&gt;[$(=replace('&lt;SPAN&gt;vChartDimension&lt;/SPAN&gt;(1)','',''))]&lt;/P&gt;&lt;P&gt;It's a trick to force Qlik to interpret text as it is.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Jul 2025 12:16:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525717#M398</guid>
      <dc:creator>Adam_Romanowski</dc:creator>
      <dc:date>2025-07-30T12:16:59Z</dc:date>
    </item>
    <item>
      <title>Re: use of dynamic variable in chart dimension</title>
      <link>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525811#M400</link>
      <description>&lt;P&gt;Hi Marcus, Thanks for your help. This has worked. This expression is working with all types of column (column with and without space).&lt;/P&gt;&lt;P&gt;Thanks for your help.&lt;/P&gt;</description>
      <pubDate>Thu, 31 Jul 2025 08:29:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Qlik-Answers/use-of-dynamic-variable-in-chart-dimension/m-p/2525811#M400</guid>
      <dc:creator>musketeers</dc:creator>
      <dc:date>2025-07-31T08:29:23Z</dc:date>
    </item>
  </channel>
</rss>

