<?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: How to conditionally remove last Char from a text field ? in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436852#M1162337</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mayil&lt;/P&gt;&lt;P&gt;Very ellegant solution worked fine&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 15 Nov 2012 16:23:54 GMT</pubDate>
    <dc:creator />
    <dc:date>2012-11-15T16:23:54Z</dc:date>
    <item>
      <title>How to conditionally remove last Char from a text field ?</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436849#M1162332</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;I have a data field that as an example contains:-&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;CB12123A&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;REQ03456&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;AT1234B&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;AT1234A&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;The A or B in the last Char cannot be guaranteed to always be in the same char position.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;What I need to do is strip off the last digit if it is an Alpha Character A or B so I end up with. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;CB12123&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;REQ03456&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;AT1234&lt;/P&gt;&lt;P style="color: #222222; font-family: arial, sans-serif; background-color: #ffffff;"&gt;AT1234&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have tried using If Statements with Right and PurgeChar but it does not give desired results.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help from the QV community would be welcome&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Nov 2012 14:15:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436849#M1162332</guid>
      <dc:creator />
      <dc:date>2012-11-15T14:15:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to conditionally remove last Char from a text field ?</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436850#M1162333</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;Try like this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=if(match(right('AT1234B',1),'A','B'),Left('AT1234B',len('AT1234B')-1))&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Nov 2012 14:25:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436850#M1162333</guid>
      <dc:creator>MayilVahanan</dc:creator>
      <dc:date>2012-11-15T14:25:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to conditionally remove last Char from a text field ?</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436851#M1162335</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try this script&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Text,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; If(Match(Right(Text, 1),'A','B'), Left(Text, len(Text)-1), Text) AS FormattedText;&lt;/P&gt;&lt;P&gt;LOAD * INLINE [&lt;/P&gt;&lt;P&gt;Text&lt;/P&gt;&lt;P&gt;CB12123A&lt;/P&gt;&lt;P&gt;REQ03456&lt;/P&gt;&lt;P&gt;AT1234B&lt;/P&gt;&lt;P&gt;AT1234A&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;jagan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Nov 2012 16:10:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436851#M1162335</guid>
      <dc:creator>jagan</dc:creator>
      <dc:date>2012-11-15T16:10:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to conditionally remove last Char from a text field ?</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436852#M1162337</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Mayil&lt;/P&gt;&lt;P&gt;Very ellegant solution worked fine&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Nov 2012 16:23:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436852#M1162337</guid>
      <dc:creator />
      <dc:date>2012-11-15T16:23:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to conditionally remove last Char from a text field ?</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436853#M1162339</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Jagan&lt;/P&gt;&lt;P&gt;I am impressed with the wealth of knowledge there is out there in the Qlikview Community&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Nov 2012 16:26:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-conditionally-remove-last-Char-from-a-text-field/m-p/436853#M1162339</guid>
      <dc:creator />
      <dc:date>2012-11-15T16:26:33Z</dc:date>
    </item>
  </channel>
</rss>

