I am getting an error in a new postgres node when using "insert or update" operation

Hi all!
I am getting an error in a new postgres node when using “insert or update” operation (see screenshot).
Error content:

Issues: There was a problem loading the parameter options from server: "Connection pool of the database object has been destroyed." .

What could this be related to, occurs in two projects using Supabase?

Moreover, when I use the old postgres node and just write a SQL query, then everything works.

Hey @Roket,

That is an interesting one it looks like there could be a couple of issues. Is the postgres instance your instance or is it managed by a Supabase install?

Supabase cloud, n8n self hosted

Hey @Roket,

Can you try removing the expressions for now and see if that gets you any closer? I have just given it a quick go with a supabase cloud account and I am able to use the Insert / Update operation.

There is nothing special in my credential

I took a screenshot to make it clearer.

2023-05-12 22-36-33

Hey @Roket,

I had the first part of that issue with the list not loading until I went into the credential but for me I was able to select the value to update.

I have just made a smaller test though and that did result in the same error message coming back, Looking at your example workflow you are using the upsert but you only have the uuid going into the node. If you add more data so it has what it needs to insert in the set node does that work?

No, it does not work on any amount of data.

That is very odd as that is what is currently working for me on a couple of different instances. Can you share the schema or create a test table and try with that?

This issue appears with two different projects (two independent Supabase accounts). I haven’t tried creating new tables yet, but I’ll try now.

The issue also appears on my table but only if I only have one field coming in, I want to make sure I fully understand what the issue actually is and how to reproduce it.

If you are seeing it with multiple input fields then there must be more to it, I need to write up a ticket for the other UI issue although that doesn’t appear to impact the query itself.

I made screenshots of data structures of two different tables from two projects. Perhaps this will help somehow.

I have just done a new test using a local Postgres database, If I pass in one option that is not being updated I get this…

This is one of 2 issues you are seeing, Now if I update my set node to include one of the fields in this case a title I get this output…

In your test if you add say the name field in the set node as well are you sure that it doesn’t work?

Could you also try with the Execute Query option as well and see if that works, We do have at least 2 bugs here that we will need to fix so at the moment I just want to make sure that we can at least get you working. The other option would be to try the supabase node and see if that works for you.

Yes, it works, I just added a boolean value true for the deleted field.
But the error is still there.

The error on the side does’t matter as much the good news here is the actual writing of data does work when used as expected which is fine.

So we just need to work out how to handle just one value which seems unlikely to happen but could happen and to work out what is going on with the UI loading.

To work around the UI issue what I did was open and close the credential then in the column to match on field click on the 3 dots and select refresh list.

It is not ideal but it will work.

1 Like

@Jon , Thank you! This is a temporary solution, but it works. Now I’ll try to set it up on real data.

1 Like

Does not work(
Here is a screenshot with real data.

Here’s something else I noticed: There are several nodes in my process (they work, but they have the same error)

Can you try using execute query instead and seeing if that works, It sounds like maybe there is an intermittent connection error as well.

Could you also try copying one of the other nodes and seeing if that works, there are 3 versions of the Postgres node so there could be something wrong with 2.1 and the other nodes might be using v2 or v1.

Perfect and what about using execute query? There isn’t going to be a quick fix for this today, have you also tried the supabase node?