<?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 select * and joins in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312434#M1192758</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It may depend on the SQL implementation, but I believe you can EITHER select * or select a list of fields and expressions, but not both.&amp;nbsp; You could just put the case logic on the QlikView side in the load instead using nested if() functions.&amp;nbsp; But honestly, I recommend against using select *.&amp;nbsp; If you're grabbing ALL fields, then someone can add a field to the database that, say, causes a join you didn't want to occur.&amp;nbsp; People adding fields to a database shouldn't have to worry if some QlikView application is going to bomb out as a result.&amp;nbsp; And you shouldn't have to worry about people adding fields to a database.&amp;nbsp; Those should be independent.&amp;nbsp; The way you achieve that independence is by explicitly listing the columns you need and only the columns you need.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 22 Jun 2011 23:58:42 GMT</pubDate>
    <dc:creator>johnw</dc:creator>
    <dc:date>2011-06-22T23:58:42Z</dc:date>
    <item>
      <title>select * and joins</title>
      <link>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312432#M1192756</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is one able to run SQL queries with joins and use the * shorthand to return all columns in the select?? I have a query that runs fine on the database itself but I get an error when loading into qlikview. The SQL is along the lines of:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select *,&lt;BR /&gt;&amp;nbsp; case&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&amp;nbsp; stuff here&lt;BR /&gt;&amp;nbsp; end financialYear&lt;/P&gt;&lt;P&gt;from table1&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; left outer join table2 on&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (linkid = linkid)&lt;BR /&gt;where&lt;BR /&gt;&amp;nbsp; stuff here&lt;BR /&gt;;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Should that be doable?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Many thanks, &lt;/P&gt;&lt;P&gt;Dave.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2011 15:43:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312432#M1192756</guid>
      <dc:creator />
      <dc:date>2011-06-22T15:43:22Z</dc:date>
    </item>
    <item>
      <title>Re: select * and joins</title>
      <link>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312433#M1192757</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dis you try using SQL prefix to your SELECT statement? e.g.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #ff0000;"&gt;SQL&lt;/SPAN&gt; select *,&lt;BR /&gt;&amp;nbsp; case&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&amp;nbsp; stuff here&lt;BR /&gt;&amp;nbsp; end financialYear&lt;/P&gt;&lt;P&gt;from table1&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; left outer join table2 on&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (linkid = linkid)&lt;BR /&gt;where&lt;BR /&gt;&amp;nbsp; stuff here&lt;BR /&gt;;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2011 16:30:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312433#M1192757</guid>
      <dc:creator>nagaiank</dc:creator>
      <dc:date>2011-06-22T16:30:15Z</dc:date>
    </item>
    <item>
      <title>select * and joins</title>
      <link>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312434#M1192758</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It may depend on the SQL implementation, but I believe you can EITHER select * or select a list of fields and expressions, but not both.&amp;nbsp; You could just put the case logic on the QlikView side in the load instead using nested if() functions.&amp;nbsp; But honestly, I recommend against using select *.&amp;nbsp; If you're grabbing ALL fields, then someone can add a field to the database that, say, causes a join you didn't want to occur.&amp;nbsp; People adding fields to a database shouldn't have to worry if some QlikView application is going to bomb out as a result.&amp;nbsp; And you shouldn't have to worry about people adding fields to a database.&amp;nbsp; Those should be independent.&amp;nbsp; The way you achieve that independence is by explicitly listing the columns you need and only the columns you need.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2011 23:58:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312434#M1192758</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-06-22T23:58:42Z</dc:date>
    </item>
    <item>
      <title>select * and joins</title>
      <link>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312435#M1192759</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the response. I gave the SQL prefix a go, but it did not solve the issue. I think the solution is as John mentions. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 23 Jun 2011 08:41:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312435#M1192759</guid>
      <dc:creator />
      <dc:date>2011-06-23T08:41:48Z</dc:date>
    </item>
    <item>
      <title>select * and joins</title>
      <link>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312436#M1192760</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Many thanks for the advice John. It seems you are correct about the use of *, and specific columns mixed. It loads fine with specific field names only.&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 23 Jun 2011 08:46:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/select-and-joins/m-p/312436#M1192760</guid>
      <dc:creator />
      <dc:date>2011-06-23T08:46:00Z</dc:date>
    </item>
  </channel>
</rss>

