<?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 WHERE field = X then FieldType? in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/WHERE-field-X-then-FieldType/m-p/448739#M167455</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have the following select statement, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SQL&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; SELECT Content,&lt;BR /&gt;&lt;BR /&gt; CustomField,&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Disabled,&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ObjectId as id&lt;BR /&gt;&lt;BR /&gt;FROM itsm.ObjectCustomFieldValues&lt;BR /&gt;&lt;BR /&gt;WHERE CustomField = 4 OR CustomField = 5 OR CustomField = 7 OR CustomField = 8&lt;BR /&gt;&lt;BR /&gt;AND Disabled = 0;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;This statement works, but I need to take CustomField where it equals 4 or 7 and make it into a field called Category, and where CustomField equals 5 or 8 into a field called SubCategory.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Can this be done?&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 23 Jan 2013 15:38:31 GMT</pubDate>
    <dc:creator />
    <dc:date>2013-01-23T15:38:31Z</dc:date>
    <item>
      <title>WHERE field = X then FieldType?</title>
      <link>https://community.qlik.com/t5/QlikView/WHERE-field-X-then-FieldType/m-p/448739#M167455</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have the following select statement, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SQL&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; SELECT Content,&lt;BR /&gt;&lt;BR /&gt; CustomField,&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Disabled,&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ObjectId as id&lt;BR /&gt;&lt;BR /&gt;FROM itsm.ObjectCustomFieldValues&lt;BR /&gt;&lt;BR /&gt;WHERE CustomField = 4 OR CustomField = 5 OR CustomField = 7 OR CustomField = 8&lt;BR /&gt;&lt;BR /&gt;AND Disabled = 0;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;This statement works, but I need to take CustomField where it equals 4 or 7 and make it into a field called Category, and where CustomField equals 5 or 8 into a field called SubCategory.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;Can this be done?&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jan 2013 15:38:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/WHERE-field-X-then-FieldType/m-p/448739#M167455</guid>
      <dc:creator />
      <dc:date>2013-01-23T15:38:31Z</dc:date>
    </item>
    <item>
      <title>Re: WHERE field = X then FieldType?</title>
      <link>https://community.qlik.com/t5/QlikView/WHERE-field-X-then-FieldType/m-p/448740#M167456</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sure, something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;T1:&lt;/P&gt;&lt;P&gt;load Content,&amp;nbsp; CustomField,&lt;/P&gt;&lt;P&gt;if(CustomField = 4 or Customfield = 7, CustomField) as Category,&lt;/P&gt;&lt;P&gt;if(CustomField = 5 or Customfield = 8, CustomField) as SubCategory,&lt;/P&gt;&lt;P&gt;Disabled,&lt;/P&gt;&lt;P&gt;id;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;SELECT Content,&lt;BR /&gt; CustomField,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Disabled,&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ObjectId as id&lt;BR /&gt;FROM itsm.ObjectCustomFieldValues&lt;BR /&gt;WHERE CustomField = 4 OR CustomField = 5 OR CustomField = 7 OR CustomField = 8&lt;BR /&gt;AND Disabled = 0;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jan 2013 15:52:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/WHERE-field-X-then-FieldType/m-p/448740#M167456</guid>
      <dc:creator>Gysbert_Wassenaar</dc:creator>
      <dc:date>2013-01-23T15:52:54Z</dc:date>
    </item>
    <item>
      <title>Re: WHERE field = X then FieldType?</title>
      <link>https://community.qlik.com/t5/QlikView/WHERE-field-X-then-FieldType/m-p/448741#M167457</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks.&amp;nbsp; That worked!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jan 2013 16:07:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/WHERE-field-X-then-FieldType/m-p/448741#M167457</guid>
      <dc:creator />
      <dc:date>2013-01-23T16:07:38Z</dc:date>
    </item>
  </channel>
</rss>

