Skip to content

Unable to import a CSV into an existing table with Primary Key (same file for testing) #5213

@jayctran

Description

@jayctran

Description

Unable to import a CSV into an existing table with exactly the same structure (and even data).

This error pops up:
{"errors": "Unable to import data into existing table. null values cannot be formatted as an SQL identifier\nCONTEXT: PL/pgSQL function msar.prepare_temp_table_for_import(text,text[]) line 61 at assignment"}

Expected behavior

Expected the same file to be imported successfully, and with Primary Key values populated.

To Reproduce

  1. I created a table with "Create Table" -> "From Data Import" - autoincrement primary key.
  2. With successfully created table, tried to "Import Data" with the exact same file and getting a NULL error.

Environment

  • Mathesar version: 0.9.0
  • OS: Linux Mint
  • Browser: Chrome
  • Browser Version: 144.0.7559.133

Additional context

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs: triageThis issue has not yet been reviewed by a maintainertype: bug

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions