Skip to main content
Skip table of contents

Neon Data in Charts [PostgreSQL]

Neon is a modern, scalable cloud platform for PostgreSQL databases designed for developers and teams who need reliable, high-performance data infrastructure.

It also provides AI-powered features in its SQL Editor, allowing you to correct queries, generate sample data, and even create realistic datasets for testing.

In this page, we demonstrate how you can connect PocketQuery to a Neon PostgreSQL database.

Preview

Bildschirmfoto 2025-10-28 um 12.28.12.png


Step 1: Create your first Neon Project

  1. Go to Neon and sign in (you can use GitHub, Google, or email).

  2. Click “Create a new project”.

  3. Enter a Project name and choose the region closest to your location

  4. Neon will automatically create a PostgreSQL database for you, along with a default user and password.

Screen of Neon Interface when creating a project

Step 2: Get your Connection String

  1. Open your newly created Neon project.

  2. In the Project Dashboard, click “Connect to your database.”

  3. In the pop-up, click “Show password” to reveal your credentials.

  4. In the connection string, you can read the user, in this example: neondb_owner.

  5. At this part of the connection string, you can read the password - it appears right after the colon (:) following the username.

  6. Copy your PostgreSQL connection string, you’ll need it in PocketQuery.

Ohne Titel 2.png

Step 3: Convert your PostgreSQL string to a JDBC URL

If you have this PostgreSQL connection string:

CODE
postgresql://neondb_owner:npg_SxwML0rtG2ZQ@ep-autumn-rain-agjrl0uv-pooler.c-2.eu-central-1.aws.neon.tech/neondb?sslmode=require&channel_binding=require

you can convert it into a JDBC URL for PocketQuery in three simple steps:

1. Replace the prefix

Change

CODE
postgresql:

to

CODE
jdbc:postgresql://

2. Remove the credentials

Delete the username and password part (neondb_owner:npg_aPFTpcwxC09h@).

You’ll enter these separately in PocketQuery as User and Password fields.

3. Keep rest as it is

CODE
jdbc:postgresql://ep-autumn-rain-agjrl0uv-pooler.c-2.eu-central-1.aws.neon.tech/neondb?sslmode=require&channel_binding=require

Final JDBC URL

Step 4: Add your Neon database to PocketQuery

Datasource

Field

Value

Name

neonDB

Type

PostgreSQL

JDBC URL

jdbc:postgresql://ep-autumn-rain-agjrl0uv-pooler.c-2.eu-central-1.aws.neon.tech/neondb?sslmode=require&channel_binding=require'

User

neondb_owner

Password

npg_aPFTpcwxC09h

Step 5: Use Neon’s built-in AI SQL Assistant to enhance your workflow:

  1. Generate realistic test data – Quickly populate your tables with sample records for dashboards or prototypes.

  2. Fix or improve SQL queries – The AI can automatically detect syntax issues or suggest optimized query versions.

  3. Experiment safely – Because Neon supports branches, you can test queries or schema changes without affecting your main database.

Once your changes are ready, refresh your PocketQuery view in Confluence to see the updated live data instantly.

Bildschirmfoto 2025-10-28 um 11.58.19.png

Step 6: Create a Query in PocketQuery

  1. In Confluence, open PocketQuery → Administration → Queries

  2. Click Create new Query

  3. Choose your Neon datasource from the dropdown and fill out Name and SQL Statement:

Field

Value

Name

Total_Sales_By_Category

SQL Statement

CODE
SELECT
  p.category AS category,
  SUM(oi.total_price) AS total_sales
FROM pq_demo.order_items oi
JOIN pq_demo.products p ON oi.product_id = p.id
GROUP BY p.category
ORDER BY total_sales DESC
  1. Click Test Query – you should see tabular results showing total sales per product category.

  2. Click Save Query to store it for later use in Confluence pages.



JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.