How to see the actual postgres query made by the node

Hey,

I have a very simple workflow:

  • I get the rows of a google sheet
  • For each row I do a postgres query with a query param with the data from the row

My query doesn’t work when I use the query param, but it works fine with static data.
I believe it’s a very simple fix, but I need to see what the actual query looks like to fix it.

For example, let’s say my query is the following:
SELECT * from customers where email = $1
And $1 is the email column from my sheet.

I look like to see the actual query for each row like:

So I can correct any errors. Now I only see the results of the query not it’s “body”.

How can I achieve that ? I’m running the desktop app.

Thanks a lot,

Matthias

Hi @tthias, welcome to the community!

n8n doesn’t have built in logging for all queries made by the Postgres node I am afraid. So you would need to configure query logging directly in the database. Check out this post for more information on how to do so:

Hey,

Thanks the quick answer, it’s seems a bit overkill for my use case but thanks a lot !

I believe having a simple execution log could be a useful to debug workflows :wink:

Matthias