How to change environment variables of Postgres integration

Hi there,

I am using Vercel’s Postgres integration, and the environment variables are directly imported into my project. However, I am unable to edit them. Due to large batch sizes, the execution times out, and I would like to add the ?connect_timeout=xy parameter to address this issue.

Can you provide guidance on how to add this parameter?

Thank you.

Hi @rmtcd!

Welcome to the Vercel Community :smiley:

Are the environment variables the one created here? As the docs say:

You can see them by navigating to the Settings tab in your project and selecting the Environment Variables panel.

From here, you can add the ?connect_timeout=xy parameter to your POSTGRES_URL?

Hi @pawlean,

yes I do see them but they seem to be read only.


image

Other environment variables do have the edit option:

image

Ah, thanks for following up!

We’re asking internally to see how we can help here. :smiley:

Appreciate your patience. :pray:

Hey @rmtcd! You can set a ?connect_timeout=x parameter by appending it to the connection string variable. So you would essentially do something like process.env.CONNECTION_STRING + '?connect_timeout=0' and assign that value to a variable in the app.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.