<?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 Linking tables and then using the value from other table. in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Linking-tables-and-then-using-the-value-from-other-table/m-p/327828#M1196039</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey John,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the reply. I thought it requires some mapping function or anything to do that. another problem what I am facing is, earlier i used to connect my QV to excel files and now I am doing that with the actual database. So , i just select the tables/fields that I want. But, if I need to use some transforamtion of the data, how could I do that? We cannot use statements like year(StartDate) in the Select statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What could be a way when you want to convert, transform etc your data , which is connected to a data source.?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks. Appreciate your reply.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 28 Jun 2011 22:53:06 GMT</pubDate>
    <dc:creator />
    <dc:date>2011-06-28T22:53:06Z</dc:date>
    <item>
      <title>Linking tables and then using the value from other table.</title>
      <link>https://community.qlik.com/t5/QlikView/Linking-tables-and-then-using-the-value-from-other-table/m-p/327826#M1196037</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am using a table that includes data of all the products&amp;nbsp; and associated details of them. This is the main table with the product ID as Table1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now, I have another table with just a prodID and Region and some other values. when I load both the tables, QV join both the tables with prodID.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now, if I want to create a graph with the values from Table 2 , I mean taking prod ID from table 2 and some of the columns from Table 1 corresponding to prodID in table 2. How can I do that?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I know its a very basic question. Sorry for posting.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Jun 2011 21:00:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Linking-tables-and-then-using-the-value-from-other-table/m-p/327826#M1196037</guid>
      <dc:creator />
      <dc:date>2011-06-28T21:00:36Z</dc:date>
    </item>
    <item>
      <title>Linking tables and then using the value from other table.</title>
      <link>https://community.qlik.com/t5/QlikView/Linking-tables-and-then-using-the-value-from-other-table/m-p/327827#M1196038</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just create a graph with fields from both tables.&amp;nbsp; There's nothing special or fancy to do.&amp;nbsp; QlikView understands the relationship between the two tables, and should give you the results you expect.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And you're in the New to QlikView forum, so there's no need to apologize for basic questions.&amp;nbsp; That's what this forum is for!&amp;nbsp; &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Jun 2011 21:11:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Linking-tables-and-then-using-the-value-from-other-table/m-p/327827#M1196038</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-06-28T21:11:22Z</dc:date>
    </item>
    <item>
      <title>Linking tables and then using the value from other table.</title>
      <link>https://community.qlik.com/t5/QlikView/Linking-tables-and-then-using-the-value-from-other-table/m-p/327828#M1196039</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey John,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the reply. I thought it requires some mapping function or anything to do that. another problem what I am facing is, earlier i used to connect my QV to excel files and now I am doing that with the actual database. So , i just select the tables/fields that I want. But, if I need to use some transforamtion of the data, how could I do that? We cannot use statements like year(StartDate) in the Select statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What could be a way when you want to convert, transform etc your data , which is connected to a data source.?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks. Appreciate your reply.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Jun 2011 22:53:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Linking-tables-and-then-using-the-value-from-other-table/m-p/327828#M1196039</guid>
      <dc:creator />
      <dc:date>2011-06-28T22:53:06Z</dc:date>
    </item>
    <item>
      <title>Re: Linking tables and then using the value from other table.</title>
      <link>https://community.qlik.com/t5/QlikView/Linking-tables-and-then-using-the-value-from-other-table/m-p/327829#M1196040</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I ALWAYS precede an SQL SELECT with a load statement, whether or not I have any transformation.&amp;nbsp; But the load statement is where you can do your transformation.&amp;nbsp; So for example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;MyID&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,if(MyName='Bob','Bobby',MyName) as MyName&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,date(date#(MyDate,'YYYYMMDD')) as MyDate&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,year(date#(MyDate,'YYYYMMDD')) as MyDate&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;SQL SELECT&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;MyID&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,MyName&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,MyDate&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;FROM MyDatabase&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mind you, I typically do not put anything but the date in the main table.&amp;nbsp; I reserve the year, month and so on for a separate calendar table, linked by the date field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The general rule is that a LOAD statement can always precede any other source, including an SQL SELECT or even another LOAD statement.&amp;nbsp; So you can stack as many LOADs right on top of each other as you want.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD *&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,month(FirstDayOfNextMonth) as NextMonth&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD *&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,monthstart(OneMonthFromNow) as FirstDayOfNextMonth&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD *&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,addmonths(Date,1) as OneMonthFromNow&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;date#(Date,'YYYYMMDD') as Date&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;SQL SELECT&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;Date&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;FROM Database&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mind you, that's a silly example, but hopefully you get the idea.&amp;nbsp; You can just keep adding fields like that.&amp;nbsp; Or by not using LOAD *, and listing fields explicitly, you can remove fields, like if you created OneMonthFromNow just to create the later fields.&amp;nbsp; A simpler way to drop fields, though, is probably just with the DROP FIELDS statement.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Jun 2011 23:11:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Linking-tables-and-then-using-the-value-from-other-table/m-p/327829#M1196040</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-06-28T23:11:59Z</dc:date>
    </item>
  </channel>
</rss>

