2 Replies Latest reply: Sep 14, 2011 8:50 AM by Sunil Chauhan RSS

    Change keys in tables?

      Hi, I met this problem. I connect thru ODBC to the data source and load 3 tables from Pervasive SQL. I have a proper ODBC driver. When I import data to the new Qlik document, Qlik makes connections between tables and use field names for that. 


      For example: I have two tables Employees and Departments. In both I have the field "Address" and in Employees field "ID_employee" and in Departments "ID_empl". Qlik makes connection using "Address", but I need to use "ID_employee" and "ID_empl". I use "ID_empl" as "ID_employee" in data input script now, but it is a workaround I think.


      Can I change this? For example to set in Qlik that key is not "Address" but those two IDs.


      Thank you for any answer.

        • Change keys in tables?
          Kaushik Solanki



              The way Qlikview joins two table, is field with same name.


              So make sure that the fields through with you want to make join in tables have the same name and the rest of the fields have distinct name.


              So in your case, the way you did is the correct way, but you need to change the name of one of the address field to something else.



          Kaushik Solanki

            • Change keys in tables?
              Sunil Chauhan

              address should not be a key. please rename this .


              writing in script


              ID_empl as ID_employee


              mak link between Departments table and Employees table.



              and your can get proper data based on ID_employee from both table.


              check both ID_employee shoould be of similar data .