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

Match Sybase dblib's handling of overlong or malformatted BCP input. #595

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ucko
Copy link
Contributor

@ucko ucko commented Jul 3, 2024

Adjust existing failure modes' boundaries and introduce the possibility of proceeding with truncated input but reporting a message (20074, aka SYBEBCOR) as a middle ground between silent truncation and noisy failure. To that end, pass _bcp_convert_in the destination's length.

@freddy77
Copy link
Contributor

This change is weird. The conditions have a final && 0 which will make this change a no-op. Are you still working on this?

Adjust existing failure modes' boundaries and introduce the
possibility of proceeding with truncated input but reporting a message
(20074, aka SYBEBCOR) as a middle ground between silent truncation and
noisy failure.  To that end, pass _bcp_convert_in the destination's
length.

Signed-off-by: Aaron M. Ucko <[email protected]>
@ucko ucko force-pushed the ncbi-2024-05-convert-truncate branch from 231bbc1 to c681ed0 Compare September 16, 2024 14:03
@ucko
Copy link
Contributor Author

ucko commented Sep 16, 2024

This change is weird. The conditions have a final && 0 which will make this change a no-op. Are you still working on this?

Not sure what happened there, sorry; I suspect I wanted to take one last look at the old behavior and accidentally left the new logic switched off. I've pushed a corrected (and rebased) version.

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

Successfully merging this pull request may close these issues.

2 participants