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

Should not decode null integer value to 0 #77

Open
rj-hwang opened this issue May 23, 2019 · 0 comments
Open

Should not decode null integer value to 0 #77

rj-hwang opened this issue May 23, 2019 · 0 comments

Comments

@rj-hwang
Copy link

Use r2dbc-h2-0.8.0.M8

create table t(id integer primary key, v integer)
insert into t(id, v) values (1, null);
StepVerifier.create(
  Mono.from(connectionFactory.create())
    .flatMap(c -> Mono.from(c.createStatement("select * from t where id = 1").execute()))
    .flatMap(result -> Mono.from(result.map((row, rowMetadata) -> row.get("v", Integer.class))))
).expectNext((Integer) null).verifyComplete();

Error:

expectation "expectNext(null)" failed (expected value: null; actual value: 0)
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