> For the complete documentation index, see [llms.txt](https://developer.kizen.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.kizen.com/docs/integrations-and-plugins/integrations/postgres/troubleshoot-postgres.md).

# Troubleshoot Postgres

{% hint style="success" %}
**Audience:** Admins, Developers, Solution Architects

**Purpose:** Describes troubleshooting methods for issues with the Postgres integration
{% endhint %}

The following table presents solutions to common issues with the Postgres integration. For additional help, see the [PostgreSQL documentation](https://www.postgresql.org/docs/).

| Issue                                                                                                                        | Cause                                                                                                                       | What to do                                                                                                                                                                                                                          |
| ---------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| You received an error message that reads: `Error while using PostgreSQL Plugin`.                                             | You have bad database credentials, an unreachable host, or an invalid query.                                                | Review the error message for more details. Update your integration secret or query, and retry.                                                                                                                                      |
| You received an error message that reads: `Error decoding JSON` .                                                            | Your integration secret isn't valid JSON.                                                                                   | Update your integration secret.                                                                                                                                                                                                     |
| You received an error message that reads: `Expected a single value result, but the query returned multiple rows or columns`. | The Return Single Value script input of the Read Data action is `true`, but the query selected more than one row or column. | Adjust your query to select exactly one value.                                                                                                                                                                                      |
| You received an error message that PostgreSQL refused the connection or that it had reached its client limit.                | Your request exceeded PosgreSQL's rate limits.                                                                              | Try again after the limit clears. To avoid this error in the future, reduce how often the <code class="expression">space.vars.automation</code> runs, narrow results with `LIMIT`, or combine multiple lookups into a single query. |
| You received an empty string.                                                                                                | The query ran successfully but matched no rows.                                                                             | This is expected behavior. An empty result returns `""`, not null.                                                                                                                                                                  |
| Your result string is truncated.                                                                                             | The result set is larger than 5 MB.                                                                                         | Target your query with `LIMIT`.                                                                                                                                                                                                     |

***

## What's Next

For details on reviewing your PostgreSQL configuration and integration secret, see [Enable Postgres in Kizen](/docs/integrations-and-plugins/integrations/postgres/enable-postgres-in-kizen.md). To access your database query, see [Add Postgres Data to an Agentic Workflow](/docs/integrations-and-plugins/integrations/postgres/add-postgres-data-to-an-agentic-workflow.md).

<details>

<summary><strong>Related Topics</strong></summary>

* [Postgres](/docs/integrations-and-plugins/integrations/postgres.md)
* [Enable Postgres in Kizen](/docs/integrations-and-plugins/integrations/postgres/enable-postgres-in-kizen.md)
* [Add Postgres Data to an Agentic Workflow](/docs/integrations-and-plugins/integrations/postgres/add-postgres-data-to-an-agentic-workflow.md)

</details>

***

*Postgres, PostgreSQL, and the Slonik Logo are trademarks or registered trademarks of the PostgreSQL Community Association of Canada. Kizen's PostgreSQL integration is not affiliated with, sponsored by, or endorsed by the PostgreSQL Community Association of Canada, the PostgreSQL Global Development Group, or the PostgreSQL Project.*


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://developer.kizen.com/docs/integrations-and-plugins/integrations/postgres/troubleshoot-postgres.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
