NeonDbError: db error: ERROR: column "google" does not exist

Good day everyone!

I’ve been trying to use one imported connection string for getServerSideProps and my API routes.

I’ve been trying the Neon serverless driver for getSeverSideProps according to this documentation:

I have a NextJS pages router project with Hasura integration.

I’ve been going between the documentation and the Neon Console to get this set up and have tried quite a few different things but I keep getting errors.

  1. If I use the HTTP Neon Serverless option in Neon Console in combination with the getServersideProps in the article I get this “NeonDbError: db error: ERROR: column “google” does not exist” error.

  2. If I use the connection string exactly as specified in the documentation (without ‘?sslmode=require’) along with its getServerSideProps function I get the same error.

  3. If I use the NeonServerless getServerSideProps in the documentation along with the Neon Console’s NextJS connection string I get a ‘Module not found: Can’t resolve ‘perf_hooks’’ error no matter how many times I install the ‘perf_hooks package’.

My API function currently looks like this:

import sql from ‘…/…/src/utils/neondb/neondb.ts’;

export default function setThemeDb(themeSetting: string, userId: string) {
sql(UPDATE settings SET theme = ${themeSetting} WHERE user_id = ${userId});
}

Thank you in advance for any assistance!

Hey @Elzabe_Els , welcome!

NeonDbError: db error: ERROR: column “google” does not exist” error.

If you go to the “Tables” page in the Neon console, do you have a column called google ?

Check if the column created as case-sensitive or not: → “Google” != “google” != “GOOGLE”

1 Like