# Connector setup with a user attribute

In this section, we'll explore the seamless process of configuring connectors to dynamically connect to specific servers based on user attributes. This functionality proves especially beneficial in scenarios involving a single-tenant data architecture, where data is distributed across various servers corresponding to different users.

{% hint style="info" %}
It's highly recommended as an App-builder to be **connected with an account that has the user attributes** used that are set. This ensures a smooth and efficient configuration process.
{% endhint %}

Let's dive into an illustrative example of how to configure a connector to establish a connection with a PostgreSQL server based on user context. The key to achieving this lies in template-based configuration, specifically manipulating the HOST field while referencing the user attribute “pg\_host”.

* Create a new connector, or edit an existing connector.
* Configure the connector following the example below, by referring to the variable for the HOST field.

  <figure><img src="/files/oZ25ZRMBp9oC4tYYuife" alt=""><figcaption></figcaption></figure>

More on variable syntaxes in this [page](/data-management-in-datahub/using-advanced-data-concepts/advanced-syntax-for-variables.md#user-attributes).

{% hint style="info" %}
If you are not connected with a user that has those attributes that are set, you can make the choice to use conditional templating syntax (given in the linked page above).
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs-v3.toucantoco.com/data-management-in-datahub/using-advanced-data-concepts/data-personnalisation-with-user-attributes/connector-setup-with-a-user-attribute.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
