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

Handle out of range value when load data #3024

Closed
zimulala opened this issue Apr 10, 2017 · 1 comment
Closed

Handle out of range value when load data #3024

zimulala opened this issue Apr 10, 2017 · 1 comment
Labels
help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.

Comments

@zimulala
Copy link
Contributor

  1. What did you do?
    If possible, provide a recipe for reproducing the error.
    create table t (a int, b int not null);
    load data local infile '/tmp/test.csv' into table t fields terminated by ' ';
    ➜ cat /tmp/test.csv
    143 1343545435346432587475

  2. What did you expect to see?
    Query OK, 1 row affected, 1 warning (0.01 sec)
    Records: 1 Deleted: 0 Skipped: 0 Warnings: 1
    mysql> select * from t;
    +------+------------+
    | a | b |
    +------+------------+
    | 143 | 2147483647 |
    +------+------------+

  3. What did you see instead?
    We ignore this insert line because we encounter a truncate error and return an empty value, but the value of b can't be null.

@ngaut ngaut added the help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. label May 6, 2017
@louishust
Copy link
Contributor

can be closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.
Projects
None yet
Development

No branches or pull requests

4 participants