<?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: LET statement to extract text variable in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433321#M796779</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What is this Field1? IS this a variable or a field from a table?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To store text values i Use set rather than Let.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you share some sample values?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Oh hold on does the Field1 has multiple values if yes you might want to use Concat() function to get multiple values. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 20 Dec 2017 03:14:04 GMT</pubDate>
    <dc:creator>vishsaggi</dc:creator>
    <dc:date>2017-12-20T03:14:04Z</dc:date>
    <item>
      <title>LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433320#M796778</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;I am using LET statement to store some text values in script. I have used the syntax &lt;/P&gt;&lt;P&gt;LET vField1 = $(Field1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when displaying values using &lt;/P&gt;&lt;P&gt;=$(vField1)&amp;nbsp; getting a&amp;nbsp; minus(-) sign.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your early response will be highly appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Jay.&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/LET-statement-to-extract-text-variable/m-p/1433320#M796778</guid>
      <dc:creator>jayabedin</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433321#M796779</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What is this Field1? IS this a variable or a field from a table?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To store text values i Use set rather than Let.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you share some sample values?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Oh hold on does the Field1 has multiple values if yes you might want to use Concat() function to get multiple values. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Dec 2017 03:14:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433321#M796779</guid>
      <dc:creator>vishsaggi</dc:creator>
      <dc:date>2017-12-20T03:14:04Z</dc:date>
    </item>
    <item>
      <title>Re: LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433322#M796780</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jaynal,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;is the Field1 is field of a table or a variable earlier calculated in the script ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if Field1 is a field of a table then u can use following code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Temp:&lt;/P&gt;&lt;P&gt;Load Field1 from table X;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LET vField1&amp;nbsp; =&amp;nbsp; peek('Field1',0,'Temp');&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH&lt;/P&gt;&lt;P&gt;Sushil&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Dec 2017 03:15:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433322#M796780</guid>
      <dc:creator>sushil353</dc:creator>
      <dc:date>2017-12-20T03:15:07Z</dc:date>
    </item>
    <item>
      <title>Re: LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433323#M796781</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sushil,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Field1 is a field in a table with multiple values.&lt;/P&gt;&lt;P&gt;If I understood you correctly the syntax peek will extract value 0 and Temp from Field1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much. i will give it a go.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Dec 2017 03:23:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433323#M796781</guid>
      <dc:creator>jayabedin</dc:creator>
      <dc:date>2017-12-20T03:23:44Z</dc:date>
    </item>
    <item>
      <title>Re: LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433324#M796782</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Vishwarath,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much for the quick response.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Field1 is a field in a table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;what would the syntax for SET statement?&lt;/P&gt;&lt;P&gt;SET vPriority_Code1 = $('PriorityMap.Priority_Code');&lt;/P&gt;&lt;P&gt;Is the syntax correct?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Dec 2017 03:40:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433324#M796782</guid>
      <dc:creator>jayabedin</dc:creator>
      <dc:date>2017-12-20T03:40:18Z</dc:date>
    </item>
    <item>
      <title>Re: LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433325#M796783</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sushil,&lt;/P&gt;&lt;P&gt;Looks like there is issue with my syntax below. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LET vPriority_Code2 = peek('PrioirityMap.Priority_Code','P1','P2');&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Dec 2017 03:45:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433325#M796783</guid>
      <dc:creator>jayabedin</dc:creator>
      <dc:date>2017-12-20T03:45:05Z</dc:date>
    </item>
    <item>
      <title>Re: LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433326#M796784</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jaynal,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;what is P1 and P2 ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Peek function will fetch a field records from a table based on the index values of the record. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;General syntax is Peek('FieldName',indexvalue,'TableName')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH&lt;/P&gt;&lt;P&gt;Sushil&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Dec 2017 03:48:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433326#M796784</guid>
      <dc:creator>sushil353</dc:creator>
      <dc:date>2017-12-20T03:48:57Z</dc:date>
    </item>
    <item>
      <title>Re: LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433327#M796785</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Index value should be a number without quote sign&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Dec 2017 03:49:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433327#M796785</guid>
      <dc:creator>sushil353</dc:creator>
      <dc:date>2017-12-20T03:49:28Z</dc:date>
    </item>
    <item>
      <title>Re: LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433328#M796786</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are you looking for Multiple values or one single value from your text field?&lt;/P&gt;&lt;P&gt;When you say $(PriorityMap.Priority_Code) is this a variable or Field name from your Load script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If PriorityMap.Priority_Code is your Field name you should try&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SET vPriority_Code = 'PriorityMap.Priority_Code';&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then use like in your textbox&lt;/P&gt;&lt;P&gt;= $(vPriority_Code)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you have multiple values you might want to add a temp table like below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Temp:&lt;/P&gt;&lt;P&gt;LOAD Concat(DISTINCT &lt;SPAN style="font-size: 13.3333px;"&gt;PriorityMap.Priority_Code&lt;/SPAN&gt;, '|') AS StringValue&lt;/P&gt;&lt;P&gt;Resident YoursourceTablename;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="text-decoration: line-through;"&gt;SET vString = '&lt;SPAN style="font-size: 13.3333px;"&gt;PriorityMap.Priority_Code&lt;/SPAN&gt;';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;SET &lt;SPAN style="font-size: 13.3333px;"&gt;vPriority_Code&lt;/SPAN&gt; = '&lt;SPAN style="font-size: 13.3333px;"&gt;StringValue&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;= $(vPriority_Code)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Dec 2017 04:15:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433328#M796786</guid>
      <dc:creator>vishsaggi</dc:creator>
      <dc:date>2017-12-20T04:15:52Z</dc:date>
    </item>
    <item>
      <title>Re: LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433329#M796787</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI Jaynal,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think because the Field1 is a field, so it will have more than 1 value in it, so the variable can not show all the values using that method.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think you need to use concat funciton like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;set vtest = =Concat(DISTINCT Field1,',');&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;Aiolos&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Dec 2017 09:13:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433329#M796787</guid>
      <dc:creator>uacg0009</dc:creator>
      <dc:date>2017-12-20T09:13:46Z</dc:date>
    </item>
    <item>
      <title>Re: LET statement to extract text variable</title>
      <link>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433330#M796788</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Aiolos,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much. You are absolutely right. Field1 is a field in a table that has multiple values.&lt;/P&gt;&lt;P&gt;I will follow this syntax. This looks nice and easy.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Jay. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 20 Dec 2017 22:07:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/LET-statement-to-extract-text-variable/m-p/1433330#M796788</guid>
      <dc:creator>jayabedin</dc:creator>
      <dc:date>2017-12-20T22:07:16Z</dc:date>
    </item>
  </channel>
</rss>

