Docker config:
postgres:
image: postgres
ports:
- "5432:5432"
volumes:
- db_data:/var/lib/postgresql/data
environment:
POSTGRES_PASSWORD: postgressecretkey
graphql-engine:
image: hasura/graphql-engine:v2.10.1
ports:
- "8080:8080"
depends_on:
- "postgres"
restart: always
environment:
HASURA_GRAPHQL_DATABASE_URL: postgres://postgres:postgressecretkey@postgres:5432/postgres
HASURA_GRAPHQL_ENABLE_CONSOLE: "true"
HASURA_GRAPHQL_ENABLED_LOG_TYPES: startup, http-log, webhook-log, websocket-log, query-log
mutation MyMutation {
insert_attendance(objects: {in: "2022-09-29T17:00:00.000-07:00"}) {
returning {
in
}
}
}
{
"data": {
"insert_attendance": {
"returning": [
{
"in": "2022-09-30T00:00:00.000+00:00"
}
]
}
}
}
I could have a separate column for the timezone, but that defeats the purpose of having a timestamptz column I think... Not sure why this is happening? Hopefully I included enough information.
Edit: "in" column information
Type: timestamp with time zone
default: now()