Problem with importing date of type timestampz

Hello guys,

I am tring the importing the field of type timestamp (ex: 2025-02-20 08:00:00) using the feature Import of Nocobase. The destiny field in collection is type Datetime (with time zone).

After the datas imported, the value in collection the field is 2025-02-19 21:00:00, the nocobase alter the value of day and hours.

Someone know why this problem ?

My environment TZ equal: TZ=America/Sao_Paulo

Please provide the following information :
1, NocoBase version number.
2, Database type.
3, Deployment method.

Hi,

1, NocoBase version number: v1.4.0-beta.5
2, Database type: Postgres 16.6-1.pgdg120+1
3, Deployment method: docker (command: docker compose -f docker-compose.yml up -d)

File docker:

version: '3'

networks:
  nocobase:
    driver: bridge

services:
  app:
    image: nocobase/nocobase:1.4.0-beta.5

    networks:
      - nocobase
    depends_on:
      - postgres
    environment:
      # The application's secret key, used to generate user tokens, etc.
      # If APP_KEY is changed, old tokens will also become invalid.
      # It can be any random string, and make sure it is not exposed.
      - APP_KEY=your-secret-key
      # Database type, supports postgres, mysql, mariadb
      - DB_DIALECT=postgres
      # Database host, can be replaced with the IP of an existing database server
      - DB_HOST=postgres
      # Database name
      - DB_DATABASE=nocobase
      # Database user
      - DB_USER=nocobase
      # Database password
      - DB_PASSWORD=nocobase
      # Timezone
      - TZ=Asia/Shanghai
    volumes:
      - ./storage:/app/nocobase/storage
    ports:
      - '13002:80'
    # init: true

  # If using an existing database server, postgres service can be omitted
  postgres:
    image: postgres:16
    restart: always
    command: postgres -c wal_level=logical
    environment:
      POSTGRES_USER: nocobase
      POSTGRES_DB: nocobase
      POSTGRES_PASSWORD: nocobase
    volumes:
      - ./storage/db/postgres:/var/lib/postgresql/data
    ports:
      - '5433:5432'
    networks:
      - nocobase

The bug has been fixed, please use the latest code to check if the issue is resolved.

1 Like