Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Highlighted
Not applicable

Need help with a data model

I am trying to build a QlikView model to represent our staffing history & projection. I am having a problem representing the case where one table is related to another table in two different ways.

For example:

I have Consultants and I have Projects as tables in my QV data model.

A Consultant is assigned to a Project, and also has a Project that they will be working on after their current Project (or maybe they don't, indicating we need to find a next Project for them). How would I build this relationship between the Consultant and the Projects? Both the current Project and next Project come from the same list of Projects.

Any help is appreciated.

Thanks,
-Simon-

Tags (1)
3 Replies
Partner
Partner

Need help with a data model

Hi Simon,

You can have two fields as CURRENT_PROJECT and NEXT_PROJECT in your CONSULTANT table. They will be pointing to the PROJECT in the PROJECT table.

Not applicable

Need help with a data model

That sounds like it would work!

How would I do that though, since the field names would be different? I thought QlikView linked on field name. Am I missing something?

Partner
Partner

Need help with a data model

Hi Simon,

Sorry it was i who missed the trick. But here is another way.

Make a table Consultant_1 with Cuurent project(Field name as PROJECT_ID) as one field also make another field as Project_Type in dat u can specify only a text as "Current" .

Make another table Consultant_2 with Next_project (Field name as PROJECT_ID) as one field also make another field as Project_Type in dat u can specify only a text as "Next" .

Now join these two tables . You can differentiate the current and next project depending on the Project_Type feild.