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

Null value fetched and no indicator defined #580

Closed
mloskot opened this issue Sep 14, 2017 · 3 comments
Closed

Null value fetched and no indicator defined #580

mloskot opened this issue Sep 14, 2017 · 3 comments
Assignees
Milestone

Comments

@mloskot
Copy link
Contributor

mloskot commented Sep 14, 2017

We have restored Oracle builds on Travis CI (#579).

Oracle build is failing due one test failure:
https://travis-ci.org/SOCI/soci/jobs/275269772

-------------------------------------------------------------------------------
String length
-------------------------------------------------------------------------------
/home/travis/build/SOCI/soci/tests/common-tests.h:4213
...............................................................................
/home/travis/build/SOCI/soci/tests/common-tests.h:4213: FAILED:
  {Unknown expression after the reported line}
due to unexpected exception with message:
  Null value fetched and no indicator defined while executing "select str,
  length(str) from soci_test order by length(str)".

The failing test was added by @vadz on 20 July in c6aef12 and I assume it has never been tried against Oracle due to missing build.

Vadim, I'm taking the liberty to pass the issue over to you :-)

@vadz
Copy link
Member

vadz commented Sep 14, 2017

Will check, thanks. Looks like a real bug in Oracle backend...

@vadz
Copy link
Member

vadz commented Sep 14, 2017

Damn, I had no idea Oracle could be that broken, but apparently it just handles empty strings in the same way as null, see e.g. https://stackoverflow.com/questions/203493/why-does-oracle-9i-treat-an-empty-string-as-null

And this looks impossible to change/work around, so I'll just have to tweak the test to deal with this.

@mloskot
Copy link
Contributor Author

mloskot commented Sep 14, 2017

This is interesting finding. I had no idea.
Yes, tweaking the tests sound like a good idea.

BTW, this reminds me bugs/annoyances between ODBC drivers - there is no way to work around it than if-else if-else test cases.

@vadz vadz closed this as completed in #582 Sep 14, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants