COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => Framework Manager => Topic started by: vzaura on 16 Sep 2015 12:40:43 PM

Title: How to make a query subject(file) the primary file
Post by: vzaura on 16 Sep 2015 12:40:43 PM
I have two files in the model. SLSWEEKPF and POSHISTPF. I want SLSWEEKPF to be the primary meaning that even if there isn't a match on the join to POSHISTPF, I want the SLSWEEKPF records to show. Currently they don't show unless there is a record in POSHISTPF. What do I need to change?
Title: Re: How to make a query subject(file) the primary file
Post by: cognostechie on 16 Sep 2015 01:06:12 PM
When the two query subjects are joined with an 'inner' join the records from any of them would show only when there is a matching record in both the tables which is what is probably happening in your case. Creating an outer join would result in showing records from one table even if there is no matching record in another table. However, changing a join from inner to outer can have adverse results so it is recommended to check it thoroughly before doing so.

The screen which shows the joins between both of them will show the 'cardinality' . This is what determines whether the join is inner or outer. 1..1 and 1..n means inner join and 0..1 and 0..n means outer join.
Title: Re: How to make a query subject(file) the primary file
Post by: vzaura on 16 Sep 2015 03:48:29 PM
It worked! Thank you!