# Setting up a foreign key filter

Availability-note[Deprecated](https://help.talend.com/r/en-US/Cloud/labels-on-talend-help-center/availability-deprecated)

This content is deprecated.

Available in...

* Data Fabric
* MDM Platform
* Qlik Talend Cloud Enterprise Edition
* Qlik Talend Cloud Premium Edition

## About this task

You can filter foreign keys based on current record values, or values extracted from the current record or complex expressions.

The following example shows how to set up a foreign key filter based on a specified value of the current record:

## Procedure

1. In the Data Model Entities area, click the foreign key element AgencyFK you have added in [Adding a foreign key to link entities](https://help.qlik.com/talend/en-US/studio-user-guide/8.0/adding-foreign-key-to-link-entities).
2. From the Properties view, click the Relationship tab.
3. Click the Foreign Key Filter tab.
4. Click the [+] button to add a line in the table.
5. Click in the XPath column and then click the ... button to open a dialog box where you can select the XPath on which to set the foreign key filter.

   ![](https://help.qlik.com/talend/en-US/studio-user-guide/Resources/images/studio_mdm-design_tab_set_foreign_key_filter.png)
6. Select Contains from the Operator list.
7. Click in the Value column and then enter Hollywood between double quotation marks in the field.

   ![](https://help.qlik.com/talend/en-US/studio-user-guide/Resources/images/studio_mdm-design_tab_set_foreign_key_filter1.png)
8. If required, add multiple conditions and combine them using various predicates.

   For more information, see [Behaviors of filters using multiple conditions and predicates in Talend MDM](https://help.qlik.com/talend/r/en-US/8.0/mdm-behaviors-of-filters).
9. Press Ctrl+S to save your changes.

## Results

For more information, see [Adding a foreign key filter](https://help.qlik.com/talend/en-US/studio-user-guide/8.0/adding-foreign-key-filter).