Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Table viewer shows extra table with name $Syn

I am having tables stu_details and dep_details,,,

stu_details contain columns id_no,name,dep_no,department

dep_details contain columns dep_no,department

when i see the table viewer one extra table shown with name $Syn1 Tabel with column fields $Syn,dep_no,department

Pls,,,,can any one explain why the unknown table created ($Syn1 Tabel)

Thanks in advance

6 Replies
Not applicable
Author

Its created because you have more than one similar feild in ur data. try renaming dep_no or department in both tables to either %_departmentKey or %_dep_noKey.

Not applicable
Author

Is it enough to change in only one table..ie changed the stu_details table 'department 'to 'dep'

How will the mappings happen if fieldnames differ in both tables?(no one matching fields in tables)

Not applicable
Author

That will work but i personally wouldnt. U can also try doing a LEFT JOIN if there isnt to much information to create one single table.

Not applicable
Author

Hi btechrames ,

When two or more input tables have two or more fields in common, this implies a composite key relationship. QlikView handles this through synthetic keys. These keys are anonymous fields that represent all occurring combinations of the composite key...

synthetic keys are formed in tables that share more than one field. Synthetic tables are used to link them.

Keep the linking field names same...

Regards

johnw
Champion III
Champion III

If you WANT the two tables to be connected by two fields, then I agree with nilupaboralessa - "Keep the linking field names same".

When you have the table viewer up, look up at the top of the screen. There's a drop down with value "Internal Table View" in it. When you see the $syn, that's a "synthetic key", which is something QlikView builds for you internally. Think of it as QlikView normalizing your data for you, if you wish. If you don't like how that looks, you can also select "Source Table View" from the drop down. You should then see no synthetic key, and just your two fields connected together. Both are equivalent. It's just two different ways of QlikView showing you that your table is connected by TWO fields instead of by one.

As long as you INTENDED for your tables to be connected by two fields, then there's nothing wrong.

BUT... most often, particularly with new developers and/or people unfamiliar with data modeling, synthetic keys will typically result from data model problems, from unintended connections in the data. So think of them as a warning. When you see them appear, just make certain that you intended those tables to connect together that way, and if not, fix the data model.

In this case, I can see no reason for the stu_details to contain the department field, unless you can have more than one department for a given dep_no. But I'm guessing that dep_no is a code for the department. Alternatively, there may be no reason to load the dep_details table at all. Is it really providing any additional information?

Miguel_Angel_Baeyens

Agree.

I have to admit that time ago I was told that synth keys were due to some problems in my data model. Time, and sometimes, unexpected attempts showed me that syn keys are really useful, and actually save some scripting time.

Anyway, for a better, real-life understanding of this feature of QlikView, it's worth reading this post regarding syn tables. I was useful, at least for me.

Regards.