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

COPY command fails with FORMAT AS JSON 'auto' #58

Open
peterlitvak opened this issue Nov 8, 2019 · 0 comments
Open

COPY command fails with FORMAT AS JSON 'auto' #58

peterlitvak opened this issue Nov 8, 2019 · 0 comments

Comments

@peterlitvak
Copy link

peterlitvak commented Nov 8, 2019

The following command:

COPY event1f0fbc67_3680_46e8_a19f_09948950d2be FROM 's3://test-redshift/event/e30aef8d-996a-404e-8a5a-899dc00d1364' 
CREDENTIALS '...' 
TIMEFORMAT 'YYYY-MM-DD HH:MI:SS'
ENCODING UTF16LE
FORMAT AS JSON 'auto';

Fails with:

jp.ne.opt.redshiftfake.FakeAmazonSQLException: Row List(Column(Some({))) has different value count then Vector(ColumnDefinition(id,Varchar), ...)

I've checked in a debugger and content is read from S3 successfully but then when it comes to:

case CopyFormat.Json(Some(jsonpathsLocation))

the execution skips it and goes to the manifest case.
It appears that only JSONPaths JSON format is supported.

@peterlitvak peterlitvak changed the title COPY command fails with UTF16LE encoding content COPY command fails with FORMAT AS JSON 'auto' Nov 8, 2019
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