<?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: Join qlikview tables with cast in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065356#M356231</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;you can not do Load * in one table and then fields name from other.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How does your SQL querry in Qlikview script&amp;nbsp; looks like?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BTW you need a key to join both table - see my first post.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 06 Apr 2016 13:36:01 GMT</pubDate>
    <dc:creator>robert_mika</dc:creator>
    <dc:date>2016-04-06T13:36:01Z</dc:date>
    <item>
      <title>Join qlikview tables with cast</title>
      <link>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065351#M356226</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey Folks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How would I perform this join in QV:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select *&lt;/P&gt;&lt;P&gt;from ExecutionReport exec&lt;/P&gt;&lt;P&gt;left join FXRate fx&lt;/P&gt;&lt;P&gt;on fx.currency = exec.currency&lt;/P&gt;&lt;P&gt;and fx.date = cast(exec.[time] as date)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2016 12:00:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065351#M356226</guid>
      <dc:creator />
      <dc:date>2016-04-06T12:00:13Z</dc:date>
    </item>
    <item>
      <title>Re: Join qlikview tables with cast</title>
      <link>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065352#M356227</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you got only one common field Qlikview will join both tables on that field&lt;/P&gt;&lt;P&gt;If you got more that one column with the same name you need to create synthetic key&lt;/P&gt;&lt;P&gt;in both table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;When you connect Qlikview to SQL base you will have to join both tables within the script similar to this&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;fx:&lt;/P&gt;&lt;P&gt;L&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;oad&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Your Fields,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="text-decoration: underline;"&gt;currency&amp;amp;'-' &amp;amp;Date as %Key&lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5em; font-size: 10pt; text-decoration: underline;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SQL SELECT *&lt;/P&gt;&lt;P&gt;FROM ....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;left join(T1)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;T2:&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;Your Fields&lt;/P&gt;&lt;P&gt;&lt;SPAN style="text-decoration: underline;"&gt;Currency &lt;/SPAN&gt;&lt;SPAN style="font-size: 13.3333px;"&gt;&lt;SPAN style="text-decoration: underline;"&gt;&amp;amp;'-' &amp;amp; &lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; text-decoration: underline;"&gt;&lt;STRONG&gt;cast&lt;/STRONG&gt;(time ) as %Key&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;SQL SELECT *&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;FROM ....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Change the &lt;STRONG&gt;cast&lt;/STRONG&gt; to Date,Date#,or Timestamp - depends on what the Date from the first table is..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Are you converting time to Date?&lt;/P&gt;&lt;P&gt;Post your script if you are still struggling.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: 'comic sans ms', sans-serif;"&gt;Feeling Qlikngry?&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;A _jive_internal="true" data-containerid="2049" data-containertype="14" data-objectid="8342" data-objecttype="102" href="https://community.qlik.com/docs/DOC-8342" style="font-weight: inherit; font-style: inherit; font-family: inherit; color: #3778c7;"&gt;How To /Missing Manual(25 articles)&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2016 12:39:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065352#M356227</guid>
      <dc:creator>robert_mika</dc:creator>
      <dc:date>2016-04-06T12:39:59Z</dc:date>
    </item>
    <item>
      <title>Re: Join qlikview tables with cast</title>
      <link>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065353#M356228</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yea exactly time is a datetime field and i need to cast it to a date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So I was wondering what the "Qlikview way" of doing the above SQL would be for those 2 joins.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2016 13:15:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065353#M356228</guid>
      <dc:creator />
      <dc:date>2016-04-06T13:15:58Z</dc:date>
    </item>
    <item>
      <title>Re: Join qlikview tables with cast</title>
      <link>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065354#M356229</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So does my anwer satisfied you?&lt;/P&gt;&lt;P&gt;If yes you can mark the question as answered.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2016 13:22:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065354#M356229</guid>
      <dc:creator>robert_mika</dc:creator>
      <dc:date>2016-04-06T13:22:52Z</dc:date>
    </item>
    <item>
      <title>Re: Join qlikview tables with cast</title>
      <link>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065355#M356230</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think im struggling even at an earlier stage. I have created an extract stage where I import FXRate table. See below. Now I need to perform the join by joining on date = time and currency = currency.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Execution_&lt;/P&gt;&lt;P&gt;LOAD *&lt;/P&gt;&lt;P&gt;FROM Execution&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And then........&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Left join(Execution)&lt;/P&gt;&lt;P&gt;LOAD date, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; currency, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; rate_eur&lt;/P&gt;&lt;P&gt;FROM FXRate&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2016 13:32:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065355#M356230</guid>
      <dc:creator />
      <dc:date>2016-04-06T13:32:39Z</dc:date>
    </item>
    <item>
      <title>Re: Join qlikview tables with cast</title>
      <link>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065356#M356231</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;you can not do Load * in one table and then fields name from other.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How does your SQL querry in Qlikview script&amp;nbsp; looks like?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BTW you need a key to join both table - see my first post.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2016 13:36:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065356#M356231</guid>
      <dc:creator>robert_mika</dc:creator>
      <dc:date>2016-04-06T13:36:01Z</dc:date>
    </item>
    <item>
      <title>Re: Join qlikview tables with cast</title>
      <link>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065357#M356232</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Execution:&lt;/P&gt;&lt;P&gt;LOAD &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; handling_instruction, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; identifier, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; last_mkt, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; market_order_id, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; market_trade_id, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; msg_seq_no, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; open_volume, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; order_id, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; own_ref, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; parent_order_id, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; price, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; session_counter, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; session_time, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; side, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sub_exec_broker, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; time_in_force, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; trade_price, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; traded_amount, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; transaction_client_id, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; transaction_user_id, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; user_id, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; volume, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; %key_MarketDateCurr, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; TurnoverSEK&lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;&lt;D&gt;&lt;/D&gt;&lt;/P&gt;&lt;P&gt;(qvd);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Left join(Execution)&lt;/P&gt;&lt;P&gt;LOAD date, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; currency, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; rate_eur&lt;/P&gt;&lt;P&gt;FROM&lt;/P&gt;&lt;P&gt;&lt;D&gt;&lt;/D&gt;&lt;/P&gt;&lt;P&gt;(qvd);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is what it looks like&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2016 13:56:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065357#M356232</guid>
      <dc:creator />
      <dc:date>2016-04-06T13:56:54Z</dc:date>
    </item>
    <item>
      <title>Re: Join qlikview tables with cast</title>
      <link>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065358#M356233</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So which fields are common in both tables?&lt;/P&gt;&lt;P&gt;I can not see any Date or time field in first table&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2016 14:07:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065358#M356233</guid>
      <dc:creator>robert_mika</dc:creator>
      <dc:date>2016-04-06T14:07:58Z</dc:date>
    </item>
    <item>
      <title>Re: Join qlikview tables with cast</title>
      <link>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065359#M356234</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;tb1.currency = tb2.currency&lt;/P&gt;&lt;P&gt;tb1.time = tb2.date&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2016 14:16:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Join-qlikview-tables-with-cast/m-p/1065359#M356234</guid>
      <dc:creator />
      <dc:date>2016-04-06T14:16:00Z</dc:date>
    </item>
  </channel>
</rss>

