Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem SQLITE-TYPE-NAME #1533

Open
4 tasks
enck19 opened this issue Oct 6, 2023 · 0 comments
Open
4 tasks

Problem SQLITE-TYPE-NAME #1533

enck19 opened this issue Oct 6, 2023 · 0 comments

Comments

@enck19
Copy link

enck19 commented Oct 6, 2023

hi,
need help to cast custom type in sqlite, my sqlite file have this structure
CREATE TABLE item (
id TEXT,
description TEXT,
um TEXT,
method_set INTEGER,
method_default INTEGER,
method_grid NUMERIC[],
method_graph NUMERIC[], level INTEGER DEFAULT 0, active INTEGER DEFAULT 0,
PRIMARY KEY(id)
);

data example on method_grid data [1,2]
data example on method_graph [3,4]

thanks

  • pgloader --version

    pgloader version "3.6.999791d" compiled with SBCL 1.4.16.debian
    
    
  • did you test a fresh compile from the source tree?

    yes

  • did you search for other similar issues?

    yes

  • how can I reproduce the bug?

--
-pgloader -v -d --context ./pgloader.ini -L pgloader.log -D workdir -S pgloader.summary  db.load
--

load database
     FROM sqlite://$path/project.db
     INTO postgresql://{{PGUSER}}:{{PGPASSWORD}}@{{DBHOST}}/{{DB}}


    WITH include drop, create tables, create indexes, reset sequences

      SET PostgreSQL PARAMETERS maintenance_work_mem to '1024MB', work_mem to '1024', search_path to '$schemanum'

       CAST
      type date drop not null drop default using zero-dates-to-null,
      type datetime to timestamp drop default using zero-dates-to-null


    BEFORE LOAD DO
   $$ drop schema IF EXISTS $schemanum cascade; $$,
   $$ create schema $schemanum; $$;


  - [ ] pgloader output you obtain
  

2023-10-06T17:43:13.069000+02:00 SQL SQLite: SELECT tbl_name
FROM sqlite_master
WHERE tbl_name = 'sqlite_sequence'
2023-10-06T17:43:13.075000+02:00 SQL SELECT tbl_name
FROM sqlite_master
WHERE type='table'
AND tbl_name <> 'sqlite_sequence'

2023-10-06T17:43:13.082000+02:00 ERROR sqlite: At

numeric[]
^ (Line 1, Column 7, Position 7)

In context SQLITE-TYPE-NAME:

While parsing SQLITE-TYPE-NAME. Problem:

The production
#\]

does not satisfy the predicate ALPHA-CHAR-P.

Expected:

the character _ (LOW_LINE)

or any character satisfying ALPHA-CHAR-P
or
2023-10-06T17:43:13.082000+02:00 LOG report summary reset
2023-10-06T17:43:13.107000+02:00 INFO Stopping monitor


  - [ ] data that is being loaded, if relevant
  

no data


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant