<?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 Two fields on a same table pointing (associating) to a single field on another table in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237914#M88898</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If it is a single attribute you are associating, I would move the City Name to the CLIENT table using either mapping or join. See attached example.&lt;/P&gt;&lt;P&gt;-Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 13 Feb 2010 10:01:07 GMT</pubDate>
    <dc:creator>rwunderlich</dc:creator>
    <dc:date>2010-02-13T10:01:07Z</dc:date>
    <item>
      <title>Two fields on a same table pointing (associating) to a single field on another table</title>
      <link>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237911#M88895</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi members of this Forum !&lt;/P&gt;&lt;P&gt;Say that you have a Client record, with a two Cities field.&lt;/P&gt;&lt;P&gt;One field is the City where the Client was BORN. The other field is the City where the Client lives. On those fields we have the CITY CODE.&lt;/P&gt;&lt;P&gt;On another table, we have the CITY CODEs and the CITY NAMES.&lt;/P&gt;&lt;P&gt;How to associate that ? Do we have to duplicate the CITY Table ? Is this the best approach ?&lt;/P&gt;&lt;P&gt;IOW :&lt;/P&gt;&lt;P&gt;&lt;PRE&gt;&lt;/PRE&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CLIENT_TABLE :&lt;/P&gt;&lt;P&gt;CLIENT_ID&lt;/P&gt;&lt;P&gt;CLIENT_NAME&lt;/P&gt;&lt;P&gt;BORN_CITY_CODE&lt;/P&gt;&lt;P&gt;ADDRESS&lt;/P&gt;&lt;P&gt;CITY_ADDRESS_CODE&lt;/P&gt;&lt;P&gt;----------&lt;/P&gt;&lt;P&gt;CITY TALBE&lt;/P&gt;&lt;P&gt;CITY CODE&lt;/P&gt;&lt;P&gt;CITY NAME&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Another approach would be to inquiry (LOOKUP) the CITY ADDRESS name during load. But that's way too slow and cumbersome.&lt;/P&gt;&lt;P&gt;Thanks in advance for your help !&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Feb 2010 19:40:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237911#M88895</guid>
      <dc:creator />
      <dc:date>2010-02-12T19:40:46Z</dc:date>
    </item>
    <item>
      <title>Two fields on a same table pointing (associating) to a single field on another table</title>
      <link>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237912#M88896</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well I've prepared a test prototype (a simple QVW).&lt;/P&gt;&lt;P&gt;There inside we need to find a way to associate the CODE_CITY field both to CITY_BORN_CLIENT field and CITY_ADDRESS_CLIENT field. Cause we need to know the NAME_CITY for both of them. And, of course they can be different for the same client.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Feb 2010 19:51:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237912#M88896</guid>
      <dc:creator />
      <dc:date>2010-02-12T19:51:14Z</dc:date>
    </item>
    <item>
      <title>Two fields on a same table pointing (associating) to a single field on another table</title>
      <link>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237913#M88897</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There are two basic approaches that I've used in similar cases.&lt;/P&gt;&lt;P&gt;1. Duplicate the city table to have a City Born table and a City Address table. That's a good approach if you want to be able to deal with both cities independently, such as finding all clients born in Paris and currently in London.&lt;/P&gt;&lt;P&gt;2. Create a linkage table between client and city, with a linkage type on each record. For your sample data:&lt;/P&gt;&lt;P style="padding-left:30px;"&gt;Name, Type, City&lt;BR /&gt;ANN, ADDRESS, NEW YORK&lt;BR /&gt;ANN, BORN, BOSTON&lt;BR /&gt;JOHN, ADDRESS, WASHINGTON&lt;BR /&gt;JOHN, BORN, WASHINGTON&lt;BR /&gt;MARY, ADDRESS, BOSTON&lt;BR /&gt;MARY, BORN, NEW YORK&lt;/P&gt;&lt;P&gt;Well, technically the linkage table would just have codes for the client and the city, but the above is easier to read in an explanation. This approach is good if you want to know all information associated with a particular city. So you select New York, and you can see that Ann lives there, and that Mary was born there, at the same time. If a chart only wants one or the other, just use set analysis to look at that specific relationship. It's also good if users will only be looking at one type of relationship at a time, allowing charts to serve dual purposes, rather than needing a born city chart and an address city chart, for instance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 13 Feb 2010 00:04:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237913#M88897</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2010-02-13T00:04:57Z</dc:date>
    </item>
    <item>
      <title>Two fields on a same table pointing (associating) to a single field on another table</title>
      <link>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237914#M88898</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If it is a single attribute you are associating, I would move the City Name to the CLIENT table using either mapping or join. See attached example.&lt;/P&gt;&lt;P&gt;-Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 13 Feb 2010 10:01:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237914#M88898</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2010-02-13T10:01:07Z</dc:date>
    </item>
    <item>
      <title>Two fields on a same table pointing (associating) to a single field on another table</title>
      <link>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237915#M88899</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;BR /&gt;It was nice to know about the MAP command :&lt;/P&gt;&lt;P&gt;MAP CITY_BORN_CLIENT, CITY_ADDRESS_CLIENT USING CITY;&lt;/P&gt;&lt;P&gt;I knew the APPLYMAP function but this command is very practical too.&lt;/P&gt;&lt;P&gt;Thanks !&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Feb 2010 16:09:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237915#M88899</guid>
      <dc:creator />
      <dc:date>2010-02-17T16:09:39Z</dc:date>
    </item>
    <item>
      <title>Two fields on a same table pointing (associating) to a single field on another table</title>
      <link>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237916#M88900</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, the duplicate table is the approach I had used before I knew the answers from my Post.&lt;/P&gt;&lt;P&gt;I used the QUALIFY *; / UNQUALIFY *; commands to insulate both tables.&lt;/P&gt;&lt;P&gt;Thanks for your help !&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Feb 2010 16:12:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Two-fields-on-a-same-table-pointing-associating-to-a-single/m-p/237916#M88900</guid>
      <dc:creator />
      <dc:date>2010-02-17T16:12:46Z</dc:date>
    </item>
  </channel>
</rss>

