<?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 Check string format pattern in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1573945#M598752</link>
    <description>&lt;P&gt;Hello all,&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;I would like to check the format of my values.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;A good format is defined like "XX999999" where XX refers to the ISO country and 999999 is a number.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Previously, I worked in Excel and I used it a regex function (VBA) but I am not familiar with QV and I have a lot of difficulties with the script editor.&lt;/P&gt;&lt;P&gt;So, I would like to use expression, for now it is more easy for me to do it.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Please do you have any advice to define simply a format in expression (from Properties of an object).&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Thank you in advance for your help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 16 Nov 2024 03:43:56 GMT</pubDate>
    <dc:creator>Black_Hole</dc:creator>
    <dc:date>2024-11-16T03:43:56Z</dc:date>
    <item>
      <title>Check string format pattern</title>
      <link>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1573945#M598752</link>
      <description>&lt;P&gt;Hello all,&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;I would like to check the format of my values.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;A good format is defined like "XX999999" where XX refers to the ISO country and 999999 is a number.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Previously, I worked in Excel and I used it a regex function (VBA) but I am not familiar with QV and I have a lot of difficulties with the script editor.&lt;/P&gt;&lt;P&gt;So, I would like to use expression, for now it is more easy for me to do it.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Please do you have any advice to define simply a format in expression (from Properties of an object).&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Thank you in advance for your help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 03:43:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1573945#M598752</guid>
      <dc:creator>Black_Hole</dc:creator>
      <dc:date>2024-11-16T03:43:56Z</dc:date>
    </item>
    <item>
      <title>Re: Check string format pattern</title>
      <link>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574002#M598753</link>
      <description>&lt;P&gt;As this is Qlikview, There is no in-built functions or support for that. Perhaps try with Macros&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/t5/QlikView-Documents/How-to-use-regular-expressions/ta-p/1477236" target="_blank"&gt;https://community.qlik.com/t5/QlikView-Documents/How-to-use-regular-expressions/ta-p/1477236&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.qlikfix.com/2010/10/18/regular-expressions-in-the-load-script/" target="_blank"&gt;http://www.qlikfix.com/2010/10/18/regular-expressions-in-the-load-script/&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Apr 2019 17:55:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574002#M598753</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2019-04-26T17:55:14Z</dc:date>
    </item>
    <item>
      <title>Re: Check string format pattern</title>
      <link>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574166#M598754</link>
      <description>&lt;P&gt;You could do something like:&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;len(keepchar(left(str,2),'ABCDEFGHIJKLMNOPQRSTUVWXYZ') = 2&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;and IsNum(right(str,6))&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;-Rob&lt;BR /&gt;&lt;A href="http://masterssummit.com" target="_blank"&gt;http://masterssummit.com&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://qlikviewcookbook.com" target="_blank"&gt;http://qlikviewcookbook.com&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://www.easyqlik.com" target="_blank"&gt;http://www.easyqlik.com&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 28 Apr 2019 08:55:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574166#M598754</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2019-04-28T08:55:55Z</dc:date>
    </item>
    <item>
      <title>Re: Check string format pattern</title>
      <link>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574322#M598755</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/5533"&gt;@Anil_Babu_Samineni&lt;/a&gt;,&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/6148"&gt;@rwunderlich&lt;/a&gt;,&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks to both of you for your precious help.&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/5533"&gt;@Anil_Babu_Samineni&lt;/a&gt;&amp;nbsp;:&amp;nbsp; Thank you for sharing the links. In the first approach to resolve my request I thought immediately to regex. So, I implemented a macro in VBscript (&lt;A href="http://www.qlikfix.com/2010/10/18/regular-expressions-in-the-load-script/" target="_self"&gt;this one&lt;/A&gt;) and then I called the function RegexTest in my Script Editor. Unfortunately, I didn't succeed. That's why, I have changed my approach to resolve my request. I hope that I can use a regex when I will be more familiar with QV.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/6148"&gt;@rwunderlich&lt;/a&gt;&amp;nbsp;: Your expression is exactly what I would like to do. So I try it in a conditional expression. But the result is always '0'.&amp;nbsp; Normally, I must obtain the value '1' if the condition is not verified and it's not the case in my table.&lt;/P&gt;&lt;P&gt;Below the table with result of the expression:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 259px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/11072iA582C0D9A8EF90F1/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;The expression of the table above:&lt;/P&gt;&lt;P&gt;if(len(keepchar(left(Cust_No,2),'ABCDEFGHIJKLMNOPQRSTUVWXYZ') = 2 and IsNum(right(Cust_No,6))),'0','1')&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Please could you tell what is wrong in my input.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Thank you in advance for your help.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Apr 2019 08:33:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574322#M598755</guid>
      <dc:creator>Black_Hole</dc:creator>
      <dc:date>2019-04-29T08:33:26Z</dc:date>
    </item>
    <item>
      <title>Re: Check string format pattern</title>
      <link>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574480#M598756</link>
      <description>&lt;P&gt;May be parenthesis placed in wrong place&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;if(len(keepchar(left(Cust_No,2),'ABCDEFGHIJKLMNOPQRSTUVWXYZ')&lt;FONT size="5" color="#FF0000"&gt;&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/FONT&gt; = 2 and IsNum(right(Cust_No,6))&lt;STRIKE&gt;&lt;FONT size="5" color="#FF0000"&gt;&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/STRIKE&gt;,'0','1')&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Apr 2019 13:05:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574480#M598756</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2019-04-29T13:05:17Z</dc:date>
    </item>
    <item>
      <title>Re: Check string format pattern</title>
      <link>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574588#M598757</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/5533"&gt;@Anil_Babu_Samineni&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Great, I correct and also I add another condition in my expression. The function runs correctly.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Please could you advise me, I have different "if"&amp;nbsp; statements depending on the country of my customer.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I would like to know what is the best way in this context to develop multiple"IF" statements.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Should I prefer to develop the different statements in the expression property of my straight table or in the edit&amp;nbsp;&lt;SPAN&gt;script ?&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I feel a little uncomfortable with the script editor. I try the following code but it's a failed.&lt;/P&gt;&lt;P&gt;Below my code in the script editor and the message error that I received:&lt;/P&gt;&lt;P&gt;/**** SCRIPT ****/&lt;/P&gt;&lt;P&gt;CUST_CHECK:&lt;BR /&gt;LOAD&lt;BR /&gt;CUST_NO,&lt;BR /&gt;if(len(keepchar(left(CUST_NO,2),'ABCDEFGHIJKLMNOPQRSTUVWXYZ') = 2 and IsNum(right(CUST_NO,6)),'0','1') AS FLAG&lt;BR /&gt;FROM CUST_TABLE ;&lt;/P&gt;&lt;P&gt;/**** ERROR MESSAGE ****/&lt;/P&gt;&lt;P&gt;File not found error&lt;/P&gt;&lt;P&gt;Cannot open file: 'C:\Users\Desktop\&lt;EM&gt;MYSERVERNAME&lt;/EM&gt;'&lt;BR /&gt;System error: Filesystem::FindImpl FindFirst call: Incorrect function: "C:\Users\Desktop"&lt;/P&gt;&lt;P&gt;****************************&lt;/P&gt;&lt;P&gt;Thank you in advance for your advice.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Apr 2019 15:44:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574588#M598757</guid>
      <dc:creator>Black_Hole</dc:creator>
      <dc:date>2019-04-29T15:44:50Z</dc:date>
    </item>
    <item>
      <title>Re: Check string format pattern</title>
      <link>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574594#M598758</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/5533"&gt;@Anil_Babu_Samineni&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Great, I corrected and I add another condition to fulfill my purpose. My expression runs right now.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Please could you advise me. &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Indeed, I have multiple "If" statement, according&lt;STRONG&gt;&amp;nbsp;to the country of&amp;nbsp;my customer.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Should I prefer to develop the different statement&amp;nbsp;in&amp;nbsp;the "expression property" of my straight table or should I write&amp;nbsp;my statement in edit script?&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;I try the following code in my edit script but&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;it's a failed (below the error message):&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;CUST_CHECK:&lt;BR /&gt;LOAD&lt;BR /&gt;Cust_No,&lt;BR /&gt;if(len(keepchar(left(Cust_No,2),'ABCDEFGHIJKLMNOPQRSTUVWXYZ')) = 2 and IsNum(right(Cust_No,6)),'0','1') as FLAG&lt;BR /&gt;FROM Cust_Table;&lt;/P&gt;&lt;P&gt;/**** ERROR MESSAGE ****/&lt;/P&gt;&lt;P&gt;File not found error&lt;/P&gt;&lt;P&gt;Cannot open file: 'C:\Users\Desktop\&lt;EM&gt;MyserverName&lt;/EM&gt;'&lt;BR /&gt;System error: Filesystem::FindImpl FindFirst call: Incorrect function: "C:\Users\Desktop"&lt;/P&gt;&lt;P&gt;CUST_CHECK:&lt;BR /&gt;LOAD&lt;BR /&gt;Cust_No,&lt;BR /&gt;if(len(keepchar(left(Cust_No,2),'ABCDEFGHIJKLMNOPQRSTUVWXYZ')) = 2 and IsNum(right(Cust_No,6)),'0','1') as FLAG&lt;BR /&gt;FROM Cust_Table;&lt;/P&gt;&lt;P&gt;Thank you in advance for your advice.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Apr 2019 16:02:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574594#M598758</guid>
      <dc:creator>Black_Hole</dc:creator>
      <dc:date>2019-04-29T16:02:21Z</dc:date>
    </item>
    <item>
      <title>Re: Check string format pattern</title>
      <link>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574597#M598759</link>
      <description>&lt;P&gt;First part, Preferably use in script as there is no complex to use.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Second part, Did you gave Library path or simply loading the external drive?&lt;/P&gt;</description>
      <pubDate>Mon, 29 Apr 2019 16:07:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574597#M598759</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2019-04-29T16:07:15Z</dc:date>
    </item>
    <item>
      <title>Re: Check string format pattern</title>
      <link>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574927#M598760</link>
      <description>&lt;P&gt;Hello&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/5533"&gt;@Anil_Babu_Samineni&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Currently I use the free version downloaded via the &lt;A href="https://www.qlik.com/us/try-or-buy/download-qlikview" target="_self"&gt;website&lt;/A&gt; but in June I will obtain the licence.&lt;/P&gt;&lt;P&gt;So, I would like to develop a solution which runs correctly even if I pass from&amp;nbsp; free version to licence.&lt;/P&gt;&lt;P&gt;But I don't understand, is it because I have the free version that's why I cannot use the Load statement in my script?&lt;/P&gt;&lt;P&gt;In my script, I would like to run something like below, do you know if it's possible?&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;LOAD&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Country, Cst_No,&lt;/P&gt;&lt;P&gt;If Country="GB" Then&lt;/P&gt;&lt;P&gt;....&lt;/P&gt;&lt;P&gt;If Country="ES" Then&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FROM &lt;/STRONG&gt;Cust_Table;&lt;/P&gt;&lt;P&gt;Thank for your help and for your time.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Apr 2019 09:39:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Check-string-format-pattern/m-p/1574927#M598760</guid>
      <dc:creator>Black_Hole</dc:creator>
      <dc:date>2019-04-30T09:39:21Z</dc:date>
    </item>
  </channel>
</rss>

